-
31 Mar 2012 10:09 PM #1
Unanswered: Scrollable within scrollable
Unanswered: Scrollable within scrollable
Is there a way to cancel event bubbling on scrollable events? I have a scrollable within another one and would like the outer to not move around when inner one's getting scrolled. I can on 'scrollstart' find the outer view and disable its scrollable, but hoping there's something less hacky...
Code:Ext.application({ name: 'Sencha', launch: function () { return Ext.create("Ext.Panel", { fullscreen: true, tabBarPosition: 'bottom', layout: { type: 'fit' }, scrollable: { direction: 'vertical' }, items: [{ layout: { type: 'vbox', align: 'sretch' }, items: [{ html: 'header', style: 'background:limegreen', height: 200 }, { style: 'background:pink', flex: 1, layout: 'fit', margin: 100, items: [{ html: 'also a scrollable section', scrollable: { direction: 'both' directionLock: true } }] }] }] }); } });
-
1 Apr 2012 8:41 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,582
- Vote Rating
- 433
- Answers
- 3101
None of the scroll events are preventable.
Mitchell Simoens @SenchaMitch
Sencha Inc, Senior Forum Manager
________________
http://www.JSONPLint.com - Source to lint your JSONP!
Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
https://github.com/mitchellsimoens
Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/
Need more help with your app? Hire Sencha Services services@sencha.com
Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is almost in print!
When posting code, please use BBCode's CODE tags.
-
1 Apr 2012 9:26 AM #3
Mitchell, thanks for responding! Perhaps let me rephrase the question... In the situation of one scrollable within another, what's the best way to prevent scrolling the outer container and localize the effect to just the inner one? Like stopping propagation of drag events within the scrollable?


Reply With Quote