1. #1
    Sencha User
    Join Date
    Jul 2012
    Posts
    6
    Answers
    2
    Vote Rating
    2
    Organa is on a distinguished road

      0  

    Default Unanswered: Listening for the same event from multiple panels

    Unanswered: Listening for the same event from multiple panels


    Hey Guys

    I'm creating multiple panels dynamically. I'd like to listen for click events from the panels.

    I'm creating objects like this:

    Code:
    var icon = {
    type: 'jobicon',
    jobLabel: iconLabel,
    jobImage: iconImage,                        
    width: iconWidth,
    height: iconHeight,
    listeners: {
     jobSelectedEvent: { fn: this.onJobIconClickEvent, scope: this } 
    }                       
    
    
    //icon.onIconTap = function(){console.log("BS Hack")};  //Oddly enough this actually works
    panel.add(icon);
    Inside my jobIcon I'm dispatching events like this:

    Code:
        onIconTap: function() {
            console.log("Dispatch event: " + this.scope);
            this.fireEvent("jobSelectedEvent", this);
        }

    The function is being called but my parent object doesn't receive it.
    Clearly I'm doing something wrong. Any help would be appreciated, thanks!

  2. #2
    Sencha User
    Join Date
    Jul 2012
    Posts
    6
    Answers
    2
    Vote Rating
    2
    Organa is on a distinguished road

      0  

    Default


    Sorry, figured it out.
    It was a scoping problem the event was being issued by an image inside of my panel

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar