Hybrid View

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Touch Premium Member
    Join Date
    Mar 2007
    Posts
    67
    Vote Rating
    0
    JeffBurr is on a distinguished road

      0  

    Default Activate Listener fires twice

    Activate Listener fires twice


    When you use setActiveItem on a Carousel to move to a specific card, the Activate event fires twice.

    Is there a workaround for this, and/or is this a known bug?

  2. #2
    Touch Premium Member
    Join Date
    Mar 2007
    Posts
    67
    Vote Rating
    0
    JeffBurr is on a distinguished road

      0  

    Default Test in example code

    Test in example code


    You can see this in action. In the examples/carousel2 folder of 1.02, add/replace the following at line 52 of index.js

    Code:
    html: rec.get('content'),
    cls: 'card ' + rec.get('cls'),
    listeners: {
        activate: function(){
            console.log(rec.internalId);
        }
    }
    You can see in the console that when you swipe, the event only fires once, but when you use the buttons (which is setActiveItem) it fires twice.

    Thanks for any help!

  3. #3
    Sencha Premium Member
    Join Date
    Feb 2011
    Posts
    60
    Vote Rating
    0
    venumobile is on a distinguished road

      0  

    Default


    I'm experiencing this also.

  4. #4
    Touch Premium Member
    Join Date
    Mar 2007
    Posts
    67
    Vote Rating
    0
    JeffBurr is on a distinguished road

      0  

    Default BUMP: Any response

    BUMP: Any response


    Is there some reason that this is being ignored by Sencha support?

    I would just like an answer as to whether there is a work-around, or if a fix will be coming in the future.

  5. #5
    Sencha User
    Join Date
    Apr 2011
    Posts
    7
    Vote Rating
    0
    tuongaz is on a distinguished road

      0  

    Default


    Has anyone had the answer?

  6. #6
    Ext JS Premium Member
    Join Date
    Feb 2009
    Posts
    16
    Vote Rating
    0
    AlexKorn is an unknown quantity at this point

      0  

    Default


    I am also experiencing this. After looking into the Card Layout's setActiveItem() code, I decided I'd leave a proper fix up to the Sencha dev team

    Here is my workaround:

    Code:
    this.on('activate', function() {
        /*
         * The activate listener fires twice, so ignore it if it's
         * recently fired
         */
        if (me.ignoreActivate) {
            return;
        }
        me.ignoreActivate = true;
        ext.defer(function() {
            me.ignoreActivate = false;
        }, 1000);
    
        // put the rest of your activation code here
    });
    By the way, this thread is about the same issue: http://www.sencha.com/forum/showthre...ires-twice-why

Similar Threads

  1. Activate event fires twice - why?
    By Tiffany A in forum Sencha Touch 1.x: Discussion
    Replies: 10
    Last Post: 30 Apr 2014, 2:10 PM
  2. getCard not available from tab activate listener
    By meyerovb in forum Sencha Touch 1.x: Bugs
    Replies: 7
    Last Post: 30 Jun 2010, 11:31 AM
  3. Listener never fires ... help
    By wgpubs in forum Ext 2.x: Help & Discussion
    Replies: 5
    Last Post: 12 Dec 2008, 3:03 AM
  4. Tabs activate listener - odd behavior
    By str2etboy in forum Ext 2.x: Help & Discussion
    Replies: 1
    Last Post: 20 Jun 2008, 9:53 AM
  5. how to get tab panel title from activate listener
    By vik in forum Ext 2.x: Help & Discussion
    Replies: 7
    Last Post: 29 May 2008, 9:58 AM

Thread Participants: 5

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