-
27 Dec 2011 8:00 AM #1
listener not working on a ToolBar
listener not working on a ToolBar
Ext version tested:
· Sencha Touch 2.0PR3
Browser versions tested against:
· Chrome 16 (Windows)
· Safari 5.1.2 (Windwos)
Tested on Iphone and Android phone as well
Description:
· Ext.Toolbar -listeners object or element object does not work when setting up the listener
through the Toolbar properties.
(It works only when using toolbar.element.on('tap', function() { alert('tap toolbar')});
Steps to reproduce the problem:
· Create an Ext.Toolbar and setup a listener
The result that was expected:
· The alert should be shown
The result that occurs instead:
· I dont know.
Test Case:
See this URL for live test caseCode:Ext.require([ 'Ext.Toolbar' ]); Ext.setup({ tabletStartupScreen: 'tablet_startup.png', phoneStartupScreen: 'phone_startup.png', icon: 'icon.png', glossOnIcon: false, fullscreen: true, onReady: function() { var toolbar = Ext.create('Ext.Toolbar', { docked: 'top', title: 'MAIN TITLE', listeners : { el : { tap : function (e, t) { console.log('tap toolbar?') } } } }); // toolbar.element.on('tap', function() {alert('tap toolbar')}); Ext.Viewport.add([toolbar]) } });
http://www.le-ri-crystal.nl/spiritue...olbartest.html
-
27 Dec 2011 8:39 AM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,656
- Vote Rating
- 435
Not sure if you did but please don't change the title to try and mark this as an open bug.
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.
-
22 Jan 2012 5:18 PM #3Sencha - Sencha Touch Dev Team
- Join Date
- Jul 2009
- Location
- Palo Alto, California
- Posts
- 469
- Vote Rating
- 9
Sencha Touch Lead Architect
Success! Looks like we've fixed this one. According to our records the fix was applied for
TOUCH-1320
in
2.0.


Reply With Quote