Code: Select all
layoutOptions = new LayoutOptions();
// options for all panes
LayoutOptions panes = new LayoutOptions();
panes.addOption("slidable", false);
panes.addOption("spacing", 6);
panes.addOption("resizeWhileDragging", false);
layoutOptions.setPanesOptions(panes);
LayoutOptions north = new LayoutOptions();
north.addOption("resizable", false);
north.addOption("size", 100);
layoutOptions.setNorthOptions(north);
// options for center pane
LayoutOptions center = new LayoutOptions();
if (pageWithLayoutPane) {
center.addOption("closable", false);
center.addOption("resizable", false);
// if container has min-width/height, then enable scrollbar(s)
center.addOption("minWidth", 200);
center.addOption("minHeight", pageWithLayoutPaneNorthSize);
}
else {
}
layoutOptions.setCenterOptions(center);
if (pageWithLayoutPane) {
// options for nested center layout
LayoutOptions childCenterOptions = new LayoutOptions();
center.setChildOptions(childCenterOptions);
// options for center-north pane
LayoutOptions centerNorth = new LayoutOptions();
centerNorth.addOption("resizable", false);
centerNorth.addOption("size", pageWithLayoutPaneNorthSize);
childCenterOptions.setNorthOptions(centerNorth);
// options for center-center pane
LayoutOptions centerCenter = new LayoutOptions();
centerCenter.addOption("minHeight", pageWithLayoutPaneNorthSize);
childCenterOptions.setCenterOptions(centerCenter);
if (getOrdersController() != null &&
getOrdersController().getShowBrowseEditOptions() &&
pageNavigationController.isPageOrdersBrowse()) {
// options for west pane
LayoutOptions west = new LayoutOptions();
west.addOption("closable", false);
west.addOption("resizable", false);
// if container has min-width/height, then enable scrollbar(s)
west.addOption("minWidth", 60);
west.addOption("minHeight", 200);
layoutOptions.setWestOptions(west);
}
}
Issue 308 in issue tracker.