1. #1
    Ext User lobo-tuerto's Avatar
    Join Date
    Dec 2007
    Posts
    234
    Vote Rating
    0
    lobo-tuerto is on a distinguished road

      0  

    Question How to hook up in checkbox on click event?

    How to hook up in checkbox on click event?


    Hi guys,


    I'm trying to hook up a function in a checkbox's onclick event, but I can only see an event named "check".

    This won't work:
    PHP Code:
                            {
                                
    xtype'xcheckbox',
                                
    fieldLabel'My checkbox:',
                                
    name'checky1',
                                
    listeners: {
                                    
    'click': function(){
                                        
    Ext.Msg.alert('Checkbox''Hi!');
                                    }
                                }
                            } 
    I don't want the 'check' event, but the clicky one.
    Any ideas?
    Dev: [Merb | Ext JS]
    Blog: Lobo tuerto
    Other projects: AztlanRPG

  2. #2
    jay@moduscreate.com's Avatar
    Join Date
    Mar 2007
    Location
    Frederick MD, NYC, DC
    Posts
    16,353
    Vote Rating
    79
    jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all jay@moduscreate.com is a name known to all

      0  

    Default


    try check not click

  3. #3
    Ext User lobo-tuerto's Avatar
    Join Date
    Dec 2007
    Posts
    234
    Vote Rating
    0
    lobo-tuerto is on a distinguished road

      0  

    Default


    Thanks for your effort, but as I said:
    I don't want the 'check' event, but the clicky one.
    Any ideas?
    Dev: [Merb | Ext JS]
    Blog: Lobo tuerto
    Other projects: AztlanRPG

  4. #4
    Ext User battisti's Avatar
    Join Date
    Oct 2007
    Location
    Brasil / PR / Cascavel
    Posts
    58
    Vote Rating
    0
    battisti is on a distinguished road

      0  

    Default


    for me the event check works perfectly
    []'s Anselmo Battisti
    anselmobattistigmail.com
    del.icio.us/anselmobattisti
    battisti.wordpress.com

  5. #5
    Ext User
    Join Date
    Jan 2008
    Location
    Jakarta
    Posts
    39
    Vote Rating
    0
    napolennon is on a distinguished road

      0  

    Default check event on checkbox

    check event on checkbox


    i've tried check event on checkbox, yes its work when i click on the checkbox's label but it doesnt work when i click in the box unless i use focus event.

  6. #6
    Ext User boriscy's Avatar
    Join Date
    Dec 2007
    Posts
    21
    Vote Rating
    0
    boriscy is on a distinguished road

      0  

    Wink Code that might help

    Code that might help


    This code might help
    PHP Code:
    var Ext.query('input.x-form-checkbox');
    Ext.each(a, function(item) {
        
    Ext.get(item).on('click', function(){alert(1)});
    }); 
    In case that you want to add just to a particular form.
    PHP Code:
    this.theForm.el.on('click',function(e){
            
    alert(e.getTarget().id);
        }, 
    this, {delegate:'input.x-form-checkbox'}); 
    Me puedes constestar en espa
    Last edited by boriscy; 1 Aug 2008 at 5:32 AM. Reason: Adding language

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi