how can I add a panel before creating the button in initComponent method of Button.js (override) file.
rum always creates one additional button panel
sorry my english is not good.
----- panel
--------- button
Printable View
how can I add a panel before creating the button in initComponent method of Button.js (override) file.
rum always creates one additional button panel
sorry my english is not good.
----- panel
--------- button
how can I add a panel before creating the button in initComponent method of Button.js (override) file.
rum always creates one additional button panel
sorry my english is not good.
----- panel
--------- button
What kind of customization are you doing? You can apply a CSS class to a Button via its Cls property.
http://docs.sencha.com/extjs/4.2.1/#...Button-cfg-cls
We recommend not to use a Panel for that. It is very-very heavy weight and, as Geoffrey already said, it is just not going to work well.
Please clarify why do you need those <div> and <a> sometimes?
Even if it would be easy possible with Buttons, we would not recommend to do it, because each Button already renders some HTML markup which is quite complex.
Ok, if you want to override the default Button, it should look like this:
Still we would suggest to change the CSS part.Code:Ext.button.Button.override({
initComponent: function() {
// your code
}
});