1. #1
    Sencha User
    Join Date
    Apr 2012
    Posts
    49
    Answers
    2
    Vote Rating
    3
    svendahlstrand is on a distinguished road

      0  

    Default Unanswered: After push event for NavigationView

    Unanswered: After push event for NavigationView


    Hello!

    Is it possible to listen for an "after push finished" event on NavigationView? The view I'm pushing takes a while to populate so I want to show a "Loading" text from the start and defer populating the view until the push and it's animations are ready.

    Right now I'm doing this in the event handler:

    Code:
    Ext.defer(function () {
      var settings = this.getSettings();
    
    
      Ext.getStore('Cards').each(function (card) {
        settings.add({xtype: 'settingscard', card: card});
      });
    }, 500, this);
    That doesn't feel good though! Is there another way? A related question: is it possible to cache the pushed view somehow? Right now I'm always creating a new one when pushing.

  2. #2
    Sencha User
    Join Date
    Feb 2011
    Location
    Düsseldorf, Germany
    Posts
    572
    Answers
    34
    Vote Rating
    31
    Kurt001 has a spectacular aura about Kurt001 has a spectacular aura about

      0  

    Default


    Can you write in a few sentences what you want to do here?

    You do add your views to the settings and add a component to each view. Is that what you are doing?
    And then you want to wait until the first view shows up?

  3. #3
    Sencha User
    Join Date
    Apr 2012
    Posts
    49
    Answers
    2
    Vote Rating
    3
    svendahlstrand is on a distinguished road

      0  

    Default


    Hi and thanks for your help Kurt! I will try with a new example:

    Code:
    Ext.define('Settings', {
      extend: 'Ext.app.Controller',
    
    
      config: {
        refs: {
          navigationView: 'navigationview',
        },
    
    
        control: {
          navigationView: {
            push: 'prepareSettings'
          }
        }
      },
    
    
      prepareSettings: function () {
        Ext.defer(function () {
          // Here I'm doing something expensive that can take
          // several seconds. I'm using defer to avoid UI freeze.
        }, 500, this);
      }
    });
    As you see I'm defering my expensive (slow) code 500 ms so that the push animation can finish. But instead I would like to listen for another event, like "pushAndAnimationFinished". Do I make any sense?

Thread Participants: 1

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