-
17 Nov 2011 6:34 AM #1
Ext.Msg.confim broken
Ext.Msg.confim broken
The callback returns undefined for the button param.
This is due to the
config.fn.call(
config.scope || null,
button.itemId || button.text,
config.input ? config.input.dom.value : null,
config
);
from the OnClick private method. Looks like you guys renamed itemId and text to private? _itemId and _text and only accessed them via getText() and so on setter/getter pattern.
But does that mean that you broke many other things that used to access the public members and should now be changed to use the accessors?
Why accessors anyway?
-
17 Nov 2011 9:16 AM #2Sencha - Sencha Touch Dev Team
- Join Date
- Mar 2007
- Location
- Redwood City, California
- Posts
- 3,652
- Vote Rating
- 14
Both of these issues have already been fixed for the next release.
-
18 Nov 2011 12:00 PM #3
Workaround
Workaround
Added the following workaround in my app.js so I could continue coding.
Regards,Code:Ext.override(Ext.MessageBox, { onClick: function(button) { if (button) { var config = button.userConfig || {}; if (typeof config.fn == 'function') { config.fn.call( config.scope || null, // override to stop getting undefines // button.itemId || button.text, button.getItemId() || button.getText(), config.input ? config.input.dom.value : null, config ); } if (config.cls) { this.el.removeCls(config.cls); } if (config.input) { config.input.dom.blur(); } } this.hide(); } } );
Bret
Looks like we can't reproduce the issue or there's a problem in the test case provided.


Reply With Quote