tags:

views:

610

answers:

2

I want to fully expand or restore a GWT HorizontalSplitPanel when the user double clicks in the panel thumb.

I was planning to extend the HorizonTalSplitPanel to add this behavior, but since it's a final class, it's not possible.

Does anybody knows a way to implement this behavior?

Thanks.

+2  A: 

Maybe you could create a class to wrap the HorizontalSplitPanel which would extend another panel (maybe a SimplePanel). The HorizontalSplitPanel would be a private field in the wrapper class.

Then you would add a DoubleClickHandler to the panel thumb which would call hSplitPanelObject.setSplitPosition(newPosition).

Does that seem workable?

DLH
+1  A: 

I have implemented something similar to DLH's suggestion, details of which are here

It works great in IE, but I've been getting sporadic behaviour in Firefox.

Elmo
Very nice article
jassuncao