public YouTubeTimestampLinkerViewModel()
        {
            YTTimestampLinker = new YTTimestampLinker(AppLogger);

            GetLinkCommand = new RelayCommand(() => YTTimestampLinker.GetLink());
            PreviewCommand = new RelayCommand(async() => await PreviewAsync());
            CopyCommand    = new RelayCommand(() => PlatformShim.CopyToClipboard(YTTimestampLinker.NewURL));
        }
Exemplo n.º 2
0
        public UUIDGeneratorViewModel()
        {
            UUIDGenerator   = new UUIDGenerator(AppLogger);
            CopyUUIDCommand = new RelayCommand(() => PlatformShim.CopyToClipboard(UUIDGenerator.UUID));

            bool uuidGenerateFunction() => UUIDGenerator.Initiate();

            ExecuteTaskCommand = new RelayCommand(async() => await InitiateProcessAsync(uuidGenerateFunction, ExecuteTaskCommand), () => !IsBusy);
        }