public class TestPanel
extends Window{
private VLayout content = null;
public TestPanel() {
super();
initPanel();
setWidth("100%");
}
private void initPanel() {
setTitle(panelHeading);
//setAutoSize(true);
setAutoHeight();
//setShowCloseButton(false);
setVPolicy(LayoutPolicy.NONE);
setOverflow(Overflow.VISIBLE);
setShowShadow(false);
setKeepInParentRect(true);
content = new VLayout();
content.setWidth("100%");
content.setHeight("100%");
addMember(content);
}
Now the problem is that when I create panels from this class,the panels does not resize automatically when I resize the main window.This works fine when I extend this class with VLayout in place of Window.But I want a collapse button in the end in the header which I cannot add while extending VLayout.Is there any property in Window or any workaround to make the panels resize automatically when I resize the main window or when the screen resolution is changed.
extends Window{
private VLayout content = null;
public TestPanel() {
super();
initPanel();
setWidth("100%");
}
private void initPanel() {
setTitle(panelHeading);
//setAutoSize(true);
setAutoHeight();
//setShowCloseButton(false);
setVPolicy(LayoutPolicy.NONE);
setOverflow(Overflow.VISIBLE);
setShowShadow(false);
setKeepInParentRect(true);
content = new VLayout();
content.setWidth("100%");
content.setHeight("100%");
addMember(content);
}
Now the problem is that when I create panels from this class,the panels does not resize automatically when I resize the main window.This works fine when I extend this class with VLayout in place of Window.But I want a collapse button in the end in the header which I cannot add while extending VLayout.Is there any property in Window or any workaround to make the panels resize automatically when I resize the main window or when the screen resolution is changed.
Comment