为了在发起某一事件后,阻止用户对界面的进行操作,可以使用ExtJS提供的针对Ext.Element的mask和unmask

例如:
1、对整个body操作
Java代码 关于ExtJS中的mask和unmask 关于ExtJS中的mask和unmask关于ExtJS中的mask和unmask
  1. function reLoadData(){   
  2.    Ext.getBody().mask("数据重新加载中,请稍等");    
  3.   
  4.    var requestConfig = {   
  5.     url : '#',//url可以根据需要设置   
  6.     callback : function(options, success, response){   
  7.         var msg = ["", , "\n""", response.responseText];   
  8.         Ext.MessageBox.alert('提示', msg.join(''));   
  9.         Ext.getBody().unmask();//去除MASK   
  10.     }   
  11.    }   
  12.   
  13.    Ext.Ajax.request(requestConfig);   
  14. }  


2、对组件实例操作
new Ext.form.FormPanel({id:'form',……});
Ext.getCmp("form").getEl().mask("数据重新加载中,请稍等");
Ext.getCmp("form").getEl().unmask();

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-12-04
  • 2022-12-23
  • 2021-05-28
  • 2021-08-17
  • 2021-06-08
  • 2022-02-01
猜你喜欢
  • 2022-01-01
  • 2022-01-03
  • 2022-12-23
  • 2022-02-14
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案