home *** CD-ROM | disk | FTP | other *** search
/ Computer Active 2010 August / CA08.iso / Multimedija / shufflr.air / ShufflrClient.swf / scripts / com / althea / client / shufflr / controller / InitDataCommand.as < prev    next >
Encoding:
Text File  |  2010-06-23  |  2.2 KB  |  59 lines

  1. package com.althea.client.shufflr.controller
  2. {
  3.    import com.althea.client.shufflr.*;
  4.    import com.althea.client.shufflr.model.*;
  5.    import org.puremvc.as3.multicore.interfaces.*;
  6.    import org.puremvc.as3.multicore.patterns.command.*;
  7.    import org.puremvc.as3.multicore.patterns.observer.*;
  8.    
  9.    public class InitDataCommand extends SimpleCommand
  10.    {
  11.       public function InitDataCommand()
  12.       {
  13.          super();
  14.       }
  15.       
  16.       override public function execute(param1:INotification) : void
  17.       {
  18.          var _loc4_:ShuffleFeedProxy = null;
  19.          var _loc5_:Object = null;
  20.          var _loc2_:String = param1.getName();
  21.          var _loc3_:Object = param1.getBody();
  22.          switch(_loc2_)
  23.          {
  24.             case ApplicationFacade.GET_INIT_DATA:
  25.                _loc4_ = facade.retrieveProxy(ShuffleFeedProxy.NAME) as ShuffleFeedProxy;
  26.                _loc5_ = new Object();
  27.                _loc5_.link = "users/invites/count";
  28.                _loc5_.dataType = ApplicationFacade.GET_INVITE_COUNT;
  29.                sendNotification(ApplicationFacade.GET_DATA,_loc5_);
  30.                _loc5_ = new Object();
  31.                _loc5_.name = "channels";
  32.                _loc5_.title = "Channels";
  33.                _loc5_.link = "navmap/browse/site";
  34.                _loc5_.dataType = "siteMenu";
  35.                sendNotification(ApplicationFacade.GET_DATA,_loc5_);
  36.                _loc5_ = new Object();
  37.                _loc5_.name = "genre";
  38.                _loc5_.title = "Genre";
  39.                _loc5_.link = "navmap/browse/genre";
  40.                _loc5_.dataType = "genreMenu";
  41.                sendNotification(ApplicationFacade.GET_DATA,_loc5_);
  42.                _loc5_ = new Object();
  43.                _loc5_.title = "Tags";
  44.                _loc5_.link = "users/tags";
  45.                _loc5_.dataType = "currUserstags";
  46.                _loc5_.name = "userTags";
  47.                _loc4_.loadData(_loc5_,_loc5_.dataType);
  48.                _loc5_ = new Object();
  49.                _loc5_.title = "Shortcuts";
  50.                _loc5_.link = "users/shortcuts";
  51.                _loc5_.dataType = "loadCurrUserChannelsView";
  52.                _loc5_.name = "shortcuts";
  53.                _loc4_.loadData(_loc5_,_loc5_.dataType);
  54.          }
  55.       }
  56.    }
  57. }
  58.  
  59.