Results 1 to 5 of 5

Thread: How to capture label tap event on checkbox fields?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Sencha Premium Member
    Join Date
    Jun 2011
    Location
    Nottingham, UK
    Posts
    24
    Vote Rating
    0
      0  

    Wink Answered: How to capture label tap event on checkbox fields?

    In sencha touch v1 you could do this:

    PHP Code:
        listeners
       {
          
    labelEl:{  
             
    tap:function () { 
                  var 
    obj Ext.getCmp('recall-0-1');                                                           
                  if (
    obj.isChecked()) {   obj.uncheck();  } 
                  else { 
    obj.check(); }
             }
          }
        } 
    This doesn't work in Touch 2 - so there must be a new way of capturing the label tap event.
    Any clues much appreciated?

    regards

    Tom

  2. you will have to do it after the component's element has been created and then do

    Code:
    cmp.label.on('tap', function() {}, cmp);

Posting Permissions

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