Multiple LoadMask
January 6th, 2009
I've got some tabpanels and in each there is a grid, i'd like to insert a LoadMask object that were shown during the charge of the grids until all grids were filled, i've tried to put a diferent loadmask on each grid's store but only the first one is applied, i know that gridpanel has an option for LoadMask but it only applies to the grid space and i want it to be applied to the whole body. Does anyone know how to do it? Thanks
Ext.override(Ext.LoadMask, {
onLoad: function() {
this.maskCount--;
if (!this.maskCount) {
this.el.unmask(this.removeMask);
}
},
onBeforeLoad: function() {
if (!this.maskCount) {
this.maskCount = 0;
}
this.maskCount++;
if (!this.disabled) {
this.el.mask(this.msg, this.msgCls);
}
},
registerStore: function(store) {
store.on('beforeload', this.onBeforeLoad, this);
store.on('load', this.onLoad, this);
store.on('loadexception', this.onLoad, this);
},
unregisterStore: function(store) {
store.un('beforeload', this.onBeforeLoad, this);
store.un('load', this.onLoad, this);
store.un('loadexception', this.onLoad, this);
}
});
Now you can use registerStore to use the LoadMask for multiple stores.
#If you have any other info about this subject , Please add it free.# |