Is their a way to center a window in a layout cell if layout is resized??
Following code snip
[code] var main_body = container_a.attachLayout({
pattern: “1C”,
offsets: {
top: 0,
right: 0,
bottom: 0,
left: 0
}
});
main_body_a = main_body.cells("a");
main_body_a.hideHeader();
main_body_a.attachHTMLString("<div id='mybody'></div>");
main_container.dhxWins.attachViewportTo(“mybody”);
var mywindow = main_container.dhxWins.createWindow({
id: “mywin”,
left: 100,
top: 100,
width: 500,
height: 300,
center: true
});
mywindow.button(“park”).hide();
mywindow.button(“minmax”).hide();
mywindow.button(“close”).hide();
mywindow.keepInViewport(true);
mywindow.denyResize();
mywindow.denyPark();
mywindow.denyMove();
mywindow.setText(“”);
mywindow.show();
[/code]
If main_body is resized the windows is not “recentered”. How to handle this?