PDA

View Full Version : reserveScrollbar: true doesn't work with vbox layout (works with anchor layout)



sarimarton
11 Dec 2013, 4:38 AM
Ext version tested:
Ext 4.2.1


Browser versions tested against:
____ IE8 FF3 (firebug 1.3.0.10 installed) Safari 4


DOCTYPE tested against:
html


Description:
reserveScrollbar: true doesn't work with vbox layout (works with anchor layout).


Steps to reproduce the problem:
make a layout with 'vbox' layout set overflowY: 'scroll' and reserveScrollbar: truebar

See https://fiddle.sencha.com/#fiddle/235
If you click among the tabs, tabs are resized according to whether the view is scrollable or not.
If you change layout to 'anchor', tabs keep their sizes with no matter of any scrollbar. reserveScrollbar works as expected.

The result that was expected:
reserveScrollbar should have effect


The result that occurs instead:
reserveScrollbar has no effect

bmacdon1
11 Dec 2013, 6:52 AM
Unfortunantly, reserveScrollbar isn't a property of the vbox layout. The reason it works on anchor layouts is because the anchor layout extends the auto layout which has the reserveScrollbar property.

Gary Schlosberg
11 Dec 2013, 7:53 AM
Thanks, bmacdon1!

The inheritance can be seen in the right column of these pages.
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.layout.container.VBox
http://docs.sencha.com/extjs/4.2.1/#!/api/Ext.layout.container.Anchor

sarimarton
11 Dec 2013, 7:57 AM
Thanks guys.