Browser: Firefox 3.6.8
SmartClient 7.0RC2
We created a window using autochild concept.
When we reuse (instantiating again with same ID) the window next time we see two buttons and header moves to the bottom of the window.
isc.defineClass("MyWindowClass","MyWindow");
isc.MyWindowClass.addProperties({
saveDefaults: {
_constructor: isc.IButton,
title: "Save",
autoFit: true,
click: function() {
....
}
},
discardDefaults: {
_constructor: isc.IButton,
title: "Discard",
autoFit: true,
click: function() {
..
}
},
initWidget: function() {
this.Super("initWidget", arguments);
this.addAutoChild("save");
this.addAutoChild("discard");
}
});
function openMyWindow () {
isc.MyWindowClass.create({
ID: "myWindowInstance"
});
myWindowInstance.show();
}
function closeWindow() {
myWindowInstance.destroy();
}
//create first time
openMyWindow();
//destroy first time
closeWindow();
//create second time
openMyWindow();
//The reason we are reusing the window is so that we change its header or labels....
SmartClient 7.0RC2
We created a window using autochild concept.
When we reuse (instantiating again with same ID) the window next time we see two buttons and header moves to the bottom of the window.
isc.defineClass("MyWindowClass","MyWindow");
isc.MyWindowClass.addProperties({
saveDefaults: {
_constructor: isc.IButton,
title: "Save",
autoFit: true,
click: function() {
....
}
},
discardDefaults: {
_constructor: isc.IButton,
title: "Discard",
autoFit: true,
click: function() {
..
}
},
initWidget: function() {
this.Super("initWidget", arguments);
this.addAutoChild("save");
this.addAutoChild("discard");
}
});
function openMyWindow () {
isc.MyWindowClass.create({
ID: "myWindowInstance"
});
myWindowInstance.show();
}
function closeWindow() {
myWindowInstance.destroy();
}
//create first time
openMyWindow();
//destroy first time
closeWindow();
//create second time
openMyWindow();
//The reason we are reusing the window is so that we change its header or labels....
Comment