protected override void InitializeCommand() { OpenLocalImageCommand = new SecureCommand(OpenLocalImageCommandExecute, CanSelectImageCommandExecute); CameraImageCommand = new SecureCommand(CameraImageCommandExecute, CanSelectImageCommandExecute); EndScreenCaptureCommand = new SecureCommand(EndScreenCaptureCommandExecute, CanEndScreenCaptureCommandExecute); StartScreenCaptureCommand = new SecureCommand(StartScreenCaptureCommandExecute, CanStartScreenCaptureCommandExecute); base.InitializeCommand(); }
public override void Initialize() { StartCapturePhotoCommand = new SecureCommand(StartCapturePhotoCommandExecute, CanStartCapturePhotoCommandExecute); SaveCapturePhotoCommand = new SecureCommand(SaveCapturePhotoCommandExecute, CanSaveCapturePhotoCommandExecute); Title = Text.CameraPhoto; capturePhoto.SetValue(Text.CapturePhoto); save.SetValue(Text.Save); base.Initialize(); }
protected override void InitializeCommand() { base.InitializeCommand(); OnMicCommandVM = new CommandViewModel(BuiltIns.OnMicCommand, this, OnMicCommandExecute); ConfigCommand = new SecureCommand(ConfigCommandExecute); PlayMusicCommand = new SecureCommand(PlayMusicCommandExecute, CanPlayMusicCommandExecute); ManageMusicCommand = new SecureCommand(ManageMusicCommandExecute, CanManageMusicCommandExecute); //RecordCommand = new SecureCommand(RecordCommandExecute); //PlayCommand = new SecureCommand(PlayCommandExecute); //StopCommand = new SecureCommand(StopCommandExecute); }
public void Consume(IConsumeContext <T> message) { var output = new SecureCommand <T>() { Command = message.Message, Credentials = new UserCredentials { Username = "******", Password = "******" }, }; message.Bus.Publish(output, x => x.ForwardUsingOriginalContext(message)); }
public CommandViewModel(Command cmd, RoomWindowViewModel owner, Action <SecureCommandArgs> execute, Func <SecureCommandArgs, bool> canExecute) : base(cmd) { if (cmd != null) { name.SetValue(cmd.Name); description.SetValue(cmd.Description); money.SetValue(cmd.Money.HasValue ? cmd.Money.Value : 0); commandType.SetValue(cmd.CommandType); SecureCommand = new SecureCommand(SecureCommandExecute, CanSecureCommandExecute) { Owner = owner }; } this.execute = execute; this.canExecute = canExecute; }
protected override void InitializeCommand() { Command = new SecureCommand(CommandExecute, CanCommandExecute); base.InitializeCommand(); }
protected override void InitializeCommand() { base.InitializeCommand(); UploadMusicCommand = new SecureCommand(UploadMusicCommandExecute, CanUploadMusicCommandExecute); DeleteMusicCommand = new SecureCommand(DeleteMusicCommandExecute, CanDeleteMusicCommandExecute); }
protected override void InitializeCommand() { SwitchUserCommand = new SecureCommand(SwitchUserCommandExecute, CanSwitchUserCommandExecute); CancelCommand = new SecureCommand(CancelCommandExecute, CanCancelCommandExecute); base.InitializeCommand(); }
protected override void InitializeCommand() { ReserveRoomCommand = new SecureCommand(ReserveRoomCommandExecute, CanReserveRoomCommandExecute); RecommendRoomCommand = new SecureCommand(RecommendRoomCommandExecute, CanRecommendRoomCommandExecute); base.InitializeCommand(); }
protected override void InitializeCommand() { OpenConfigurationCommand = new SecureCommand(OpenConfigurationCommandExecute, CanOpenConfigurationCommandExecute); SelectUserCommand = new SecureCommand(SelectUserCommandExecute, CanSelectUserCommandExecute); base.InitializeCommand(); }
protected override void InitializeCommand() { TryNowCommand = new SecureCommand(TryNowCommandExecute, CanTryNowCommandExecute); base.InitializeCommand(); }
protected override void InitializeCommand() { SaveCommand = new SecureCommand(SaveCommandExecute, CanSaveCommandExecute); ResetCommand = new SecureCommand(ResetCommandExecute, CanResetCommandExecute); base.InitializeCommand(); }