乡下人产国偷v产偷v自拍,国产午夜片在线观看,婷婷成人亚洲综合国产麻豆,久久综合给合久久狠狠狠9

  • <output id="e9wm2"></output>
    <s id="e9wm2"><nobr id="e9wm2"><ins id="e9wm2"></ins></nobr></s>

    • 分享

      ext.button 常用 函數(shù) 屬性

       小花驢 2015-05-13

      var buttonName = new Ext.Button({
                     id:"buttonName",
                     text:"Button組件基本用法",
                     tooltip:"提示信息:Button組件基本用法",
                     //提示信息,如果需要顯示提示信息,需要使用Ext.QuickTips.init();        
                     tooltipType:"title", //定義顯示提示信息的類型,有qtip和title兩種方式,默認(rèn)是qtip
                   
                     type:"button", //按鈕類型:可以是submit, reset or button  默認(rèn)是 button
                   
                     autoShow:true, //默認(rèn)false,自動(dòng)顯示
                  
                     hidden:false, //默認(rèn)false,是否隱藏
                  
                     hideMode:"offsets", //隱藏方式,默認(rèn)display,可以取值:display,offsets,visibility           
                     cls:"cssButton", //樣式定義,默認(rèn)""
                  
                     disabled:false, //是否可用,默認(rèn)false
                  
                     disabledClass:"", //默認(rèn)x-item-disabled
                  
                     enableToggle:true, //默認(rèn)false
                  
                     pressed:false, //設(shè)置按鈕是否已經(jīng)被按下,默認(rèn)是false
                  
                     html:"Ext",//默認(rèn)""
                  
                     handleMouseEvents:true, //默認(rèn)true,如果為false,那么mouseout mouseover就不能被觸發(fā)
                   
                    //x:number,y:number,在容器中的x,y坐標(biāo) 
                   
                     handler:function(){Ext.Msg.alert('提示消息框','測(cè)試Button組件:handler事件!');},//添加事件
                  
                     listeners:{//添加監(jiān)聽事件 可以結(jié)合handler測(cè)試這兩個(gè)事件哪個(gè)最先執(zhí)行
                        "click":function(){
                             Ext.Msg.alert('提示消息框','測(cè)試Button組件:listeners事件!');
                             Ext. getCmp_r("buttonName").hide();//隱藏按鈕
                        }
                    },
                  
                     cls:"x-btn-text-icon",//添加圖標(biāo)前需要設(shè)置該屬性
                   
                     icon:"house.gif", //圖標(biāo)的地址
                  
                     //plugins : Object/Array 擴(kuò)展插件時(shí)使用
                  
                     repeat:false, //默認(rèn)false ,如果為true,需要設(shè)置mouseover事件
                  
                     renderTo:"Bind_Button" //將組件的顯示效果渲染到某個(gè)節(jié)點(diǎn)的ID
                   
              });
      配置:
      1. id:"buttonName",
      2. text:"Button組件基本用法",
      3. tooltip:"提示信息:Button組件基本用法", //提示信息,如果需要顯示提示信息,需要使用Ext.QuickTips.init();
      4. ooltipType:"title", //定義顯示提示信息的類型,有qtip和title兩種方式,默認(rèn)是qtip
      5. ype:"button", //按鈕類型:可以是submit, reset or button  默認(rèn)是 button
      6. autoShow:true, //默認(rèn)false,自動(dòng)顯示
      7. hidden:false, //默認(rèn)false,是否隱藏
      8. hideMode:"offsets", //隱藏方式,默認(rèn)display,可以取值:display,offsets,visibility
      9. cls:"cssButton", //樣式定義,默認(rèn)""
      10. disabled:false, //是否可用,默認(rèn)false
      11. disabledClass:"", //默認(rèn)x-item-disabled
      12. enableToggle:true, //默認(rèn)false
      13. pressed:false, //設(shè)置按鈕是否已經(jīng)被按下,默認(rèn)是false
      14. html:"Ext",//默認(rèn)""
      15. handleMouseEvents:true, //默認(rèn)true,如果為false,那么mouseout mouseover就不能被觸發(fā)
      16. x:number,y:number,在容器中的x,y坐標(biāo) 
      17. handler:function(){Ext.Msg.alert('提示消息框','測(cè)試Button組件:handler事件!');},//添加事件
      18. listeners:{//添加監(jiān)聽事件 可以結(jié)合handler測(cè)試這兩個(gè)事件哪個(gè)最先執(zhí)行
               "click":function(){
                   Ext.Msg.alert('提示消息框','測(cè)試Button組件:listeners事件!');
                   Ext. getCmp_r("buttonName").hide();//隱藏按鈕
                 }
         },
      19. cls:"x-btn-text-icon",//添加圖標(biāo)前需要設(shè)置該屬性
      20. icon:"house.gif", //圖標(biāo)的地址
      21. plugins : Object/Array 擴(kuò)展插件時(shí)使用
      22. repeat:false, //默認(rèn)false ,如果為true,需要設(shè)置mouseover事件
      23. renderTo:"Bind_Button" //將組件的顯示效果渲染到某個(gè)節(jié)點(diǎn)的ID

      常用方法:
      1. enable();激活按鈕
      2. disable();禁用按鈕
      3. destroy();消滅按鈕
      4. focus();按鈕獲取焦點(diǎn)
      5. getText_r();獲取按鈕上的文本
      6. hide();隱藏按鈕
      7. show();顯示按鈕
      8. setText( String text );設(shè)置按鈕上的文本
      9. setVisible( Boolean visible );設(shè)置按鈕是否隱藏
      10. buttonName.purgeListeners();
      //使用該方法,意思是清除所有的監(jiān)聽事件,所以當(dāng)執(zhí)行該句后就不會(huì)再執(zhí)行l(wèi)isteners的click事件了。按鈕就不會(huì)被隱藏了。
      11. buttonName.setHandler(fn);       
              //也可以通過(guò)這種方式設(shè)置handler事件:
              buttonName.setHandler(function(){Ext.Msg.alert('提示消息框','測(cè)試Button組件:setHandler事件!');});
      12. buttonName.on(eventName,fn);
             //下面的事件可以自己測(cè)試下
              buttonName.on("click",function(){
                  Ext.Msg.alert('提示消息框','測(cè)試Button組件:click事件!');
              });
               buttonName.on("mouseover",function(){
                  Ext.Msg.alert('提示消息框','測(cè)試Button組件:mouseover事件!');
              });

              buttonName.on("mouseout",function(){
                  Ext.Msg.alert('提示消息框','測(cè)試Button組件:mouseout事件!');
              });

                   
      mouseout : ( Button this, Event e ) ;
      mouseover : ( Button this, Event e );
      beforedestroy : ( Ext.Component this ) ;
      beforehide : ( Ext.Component this ) ;
      beforerender : ( Ext.Component this )
      beforeshow : ( Ext.Component this )
      click : ( Button this, EventObject e )
      destroy : ( Ext.Component this )
      disable : ( Ext.Component this )
      enable : ( Ext.Component this )
      hide : ( Ext.Component this )
      show : ( Ext.Component this )
      render : ( Ext.Component this )

        本站是提供個(gè)人知識(shí)管理的網(wǎng)絡(luò)存儲(chǔ)空間,所有內(nèi)容均由用戶發(fā)布,不代表本站觀點(diǎn)。請(qǐng)注意甄別內(nèi)容中的聯(lián)系方式、誘導(dǎo)購(gòu)買等信息,謹(jǐn)防詐騙。如發(fā)現(xiàn)有害或侵權(quán)內(nèi)容,請(qǐng)點(diǎn)擊一鍵舉報(bào)。
        轉(zhuǎn)藏 分享 獻(xiàn)花(0

        0條評(píng)論

        發(fā)表

        請(qǐng)遵守用戶 評(píng)論公約

        類似文章 更多