PDA

View Full Version : [CLOSED] Configure the Confirmīs default button



RCN
Jun 19, 2012, 12:30 PM

Daniil
Jun 19, 2012, 1:12 PM
Hi,

I can suggest to use the defaultFocus functionality.
http://docs.sencha.com/ext-js/4-1/#!/api/Ext.window.Window-cfg-defaultFocus

The "No" button has "2" index.

Example

Ext.Msg.on(
"beforeshow",
function (win) {
win.defaultFocus = 2;
},
null, {
single : true
}
);
Ext.Msg.confirm(titulo, descricao, function (btn) {
if (btn == 'yes') {
alert("Ext.Net");
}
});

RCN
Jun 19, 2012, 1:51 PM
Thank you Daniil, Please mark it as closed