Command that execute always without any can execute condition
Наследование: ICommand
Пример #1
0
 /// <summary>
 /// Constructor that initializes the commands and the local reference to the peer
 /// </summary>
 /// <param name="peer">Peer that will be used to get information from the network</param>
 public SearchListModel(Peer peer = null)
 {
     this.peer        = peer;
     Query            = "";
     Search           = new AlwaysExecuteCommand(searchFn);
     RaiseStartStream = new AlwaysExecuteCommand(startStream);
 }
Пример #2
0
 /// <summary>
 /// Constructor that initializes the commands and the local reference to the peer
 /// </summary>
 /// <param name="peer">Peer that will be used to get information from the network</param>
 public SearchListModel(Peer peer=null)
 {
     this.peer = peer;
     Query = "";
     Search = new AlwaysExecuteCommand(searchFn);
     RaiseStartStream = new AlwaysExecuteCommand(startStream);
 }
Пример #3
0
 /// <summary>
 /// Constructor that initializes all commands and the reference to the Peer.
 /// </summary>
 /// <param name="p"></param>
 public AudioPlayerModel(Peer p = null)
 {
     //player.Done += new PlayerEx.DoneEventHandler(player_Done);
     //player.SetVolume(200, 200);
     player.PlaybackStopped += new EventHandler(playback_stopped);
     this.peer = p;
     Play      = new AlwaysExecuteCommand(play);
     Pause     = new AlwaysExecuteCommand(pause);
     Stop      = new AlwaysExecuteCommand(stop);
     Close     = new AlwaysExecuteCommand(close);
     MaxVolume = 1.0F;
     Volume    = 0.4F;
 }
Пример #4
0
 /// <summary>
 /// Constructor that initializes all commands and the reference to the Peer.
 /// </summary>
 /// <param name="p"></param>
 public AudioPlayerModel(Peer p = null)
 {
     //player.Done += new PlayerEx.DoneEventHandler(player_Done);
        //player.SetVolume(200, 200);
     player.PlaybackStopped += new EventHandler(playback_stopped);
     this.peer = p;
     Play = new AlwaysExecuteCommand(play);
     Pause = new AlwaysExecuteCommand(pause);
     Stop = new AlwaysExecuteCommand(stop);
     Close = new AlwaysExecuteCommand(close);
     MaxVolume = 1.0F;
     Volume = 0.4F;
 }
Пример #5
0
 /// <summary>
 /// Constructor that initializes the commands and the local reference to the peer
 /// </summary>
 /// <param name="p">Peer that will be used to get information</param>
 public LocalStoreModel(Peer p = null)
 {
     peer = p;
     RefreshList = new AlwaysExecuteCommand(refreshList);
     refreshList();
 }
Пример #6
0
 /// <summary>
 /// Constructor that initializes the commands and the local reference to the peer
 /// </summary>
 /// <param name="p">Peer that will be used to get information</param>
 public LocalStoreModel(Peer p = null)
 {
     peer        = p;
     RefreshList = new AlwaysExecuteCommand(refreshList);
     refreshList();
 }