Results 1 to 4 of 4

Thread: Checkbox?boxLabel????????

  1. #1

    Default Checkbox?boxLabel????????

    ???????????????????

    Form?Checkbox??????ON/OFF?????
    boxLabel????????????????????

    API???????????????
    ???????????????????????
    ?????????????????????????????????

    ???????????????????????????

  2. #2
    Sencha Premium Member amanoman's Avatar
    Join Date
    Oct 2007
    Location
    ??
    Posts
    49

    Default ???boxLabel???????plugin?????????

    ????boxLabel???????????????????????
    boxLabel???????????????????
    ???????????????????????
    ExtJS 2.X????
    PHP Code:
    /**
     * @class Ext.ux.CheckBoxLabelSet
     * Ext.form.Checkbox?setBoxLabel??????????????(Ext.form.Radio??????)
     * ?????setBoxLabel
     * ?????????(?????boxLabel??)
     * ??????:
     * ?????????????????boxLabel??????
     * var checkbox=new Ext.form.Checkbox({
     *      boxLabel:'FALSE',
     *      plugins:new Ext.ux.CheckBoxLabelSet(),
     *      handler:function(c,v) {
     *          if (v) {
     *               //???????????????
     *         c.setBoxLabel('TRUE');
     *          } else {
     *               //???????????????
     *              c.setBoxLabel('FALSE');
     *        }
     *    }
     * });
     * checkbox.render(document.body);
     * 
     * @constructor
     * Ext.ux.CheckBoxLabelSet????????
     */
    Ext.ns('Ext.ux.CheckBoxLabelSet');
    Ext.ux.CheckBoxLabelSet=function() {
        
    this.init=function(cmp) {
            
    cmp.setBoxLabel=function(label) {
                if (
    label) {
                    
    this.boxLabel=label;
                    if (!
    this.labelEl) {
                        
    this.labelEl this.innerWrap.createChild({
                            
    tag'label',
                            
    htmlForthis.el.id,
                            
    cls'x-form-cb-label',
                            
    htmlthis.boxLabel
                        
    });
                    } else {
                        
    this.labelEl.update(this.boxLabel);
                    }
                }
            }
        }


  3. #3

    Default ????????????

    ??????????????????????????????????

    ????ExtJS 2.1??????innerWrap??????????????

    ??????????????????????????????????????

    ????????????

  4. #4
    Sencha Premium Member amanoman's Avatar
    Join Date
    Oct 2007
    Location
    ??
    Posts
    49

    Default

    Quote Originally Posted by kuroneko View Post
    ??????????????????????????????????

    ????ExtJS 2.1??????innerWrap??????????????

    ??????????????????????????????????????

    ????????????
    >????ExtJS 2.1??????innerWrap??????????????
    ?????????
    ???2.2.1?????????????????????

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •