title: backbone.js do something when event (vent) is complete?
body: <pre><code>$('button').click(function(){
    App.vent.trigger("box:change");
  });
  
  App.BoxView = Backbone.View.extend({
    initialize: function(options) {
  
      this.listenTo( App.vent, "box:change", this.alter ); // animate, etc.
    },
  
    ...
  
  });
  </code></pre>
  
  <p>I have a main view, in wich i wish to do some changes when (and/or):</p>
  
  <ol>
  <li>the event is processed by all my boxes</li>
  <li>all my boxes done with some animations</li>
  </ol>
  
  <p>can't wrap my head around this(long work day)... 
  please help =) 
  what is the better practice? </p>
  
  <p>i'm looking for something like this:</p>
  
  <pre><code>App.MainView = Backbone.View.extend({
        initialize: function(options) {
  
          // when all the events are complete
          this.listenTo( App.vent, "box:change" ).onComplete( this.rearrange_stuff );
  
          // when all the animations are complete
          this.listenTo( App.animationBuffer, "box:fadeOut" ).onComplete( this.rearrange_stuff );
  
        },
  
        ...
  
  });
  </code></pre>
  
  <p>update:
    and what if I have a long chain of events - complete - events - complete (not loop) in my application, what is the better way to set this queue?</p>