PDA

View Full Version : change properties of a region of BorderLayout



rojar
14 Feb 2007, 2:38 AM
Hello

Can we change properties of region of BorderLayout on some event.

For example:-

If I am using BorderLayout




var layout = new YAHOO.ext.BorderLayout(document.body, {
north: {
initialSize: 25,
titlebar: false
},
west: {
split:true,
initialSize: 200,
minSize: 175,
maxSize: 400,
titlebar: true,
collapsible: true
},
east: {
split:true,
initialSize: 202,
minSize: 175,
maxSize: 400,
titlebar: true,
collapsible: true
},
south: {
split:true,
initialSize: 100,
minSize: 100,
maxSize: 200,
titlebar: true,
collapsible: true
},
center: {
titlebar: true,
autoScroll:true,
resizeTabs: true,
minTabWidth: 50,
preferredTabWidth: 150
}
});




I have provided a checkboxes--for titlebar and collapsible properties of south region.
How can I set property 'collapsible'=false or true depending upon if checkbox is checked or not



:) Thanks

Animal
14 Feb 2007, 3:38 AM
myRegion.collapseBtn.hide();


File an enhancement request for



myRegion.setCollapsible(false/true);


Similarly for the title:



myRegion.titleEl.hide();