Selection and resizing problem using JgoControl

I have implemented JGoTable and GoTableNode much like your example for the TreeApp with JGoTree and GoTreeNode. The JGoTable has a JPanel with a banner and a JTable control. Everything works fine except for this. Since the underlying Simplenode is hidden by the JGoControl, there seems to be no way to get the resizing handles to show unless you carefully click on the border of the node and drag it to a new location. Then the handles show and you can resize the node correctly. I tried to add a mouselistener to the JPanel and do a view.selectobject(getparentjgonode(). This works great and shows the resize handles. However, when I resize the node, the handles expand but the underlying JPanel and JTable stay the same. Any help would be greatly appreciated.

Did you implement the layoutChildren method on GoTableNode? You’ll want to get the bounding rectangle of the of your node and then make sure that the bounding rectangle of your JGoTable is the same size or smaller. Take a look at GoTreeNode layoutChildren for an example.


I was doing a layoutchildren but I was not setting the bounds on the JGoTable but the Jpanel inside. This corrected the problem however, There is one more thing. Now that the selection and the resizing work, I can't get the node to move now. It did move before as I mentioned when I was not doing a selectobject.


I fixed the problem by also doing the enablelisteners method from the example. This seems to pass the events up the chain. Thanks for your help and consider this closed.