コード例 #1
0
ファイル: LoginViewModel.cs プロジェクト: RomanGL/OneVK-WP8.1
        /// <summary>
        /// Инициализирует новый экземпляр класса <see cref="LoginViewModel"/>.
        /// </summary>
        /// <param name="navigationService">Сервис навигации.</param>
        /// <param name="loginService">Сервис авторизации ВКонтакте.</param>
        public LoginViewModel(INavigationService navigationService, IVKLoginService loginService,
                              IVKLongPollService vkLongPollService)
        {
            this.navigationService = navigationService;
            this.loginService      = loginService;

            LoginCommand = new DelegateCommand(OnLoginCommand);
        }
コード例 #2
0
ファイル: TestViewModel.cs プロジェクト: RomanGL/OneVK-WP8.1
        public TestViewModel(IAppNotificationsService appNotificationsService, IVKLongPollService vkLongPollService,
                             IGrooveMusicService gms, IPushNotificationsService pushNotificationsService, ISettingsService settingsService)
        {
            this.appNotificationsService = appNotificationsService;
            this.vkLongPollService       = vkLongPollService;
            this.gms = gms;
            this.pushNotificationsService = pushNotificationsService;
            this.settingsService          = settingsService;

            ShowSimplePush = new DelegateCommand <string>(OnShowSimplePush);
            ShowCustomPush = new DelegateCommand(OnShowCustomPush);
            DeserializeLongPollResponse = new DelegateCommand(OnDeserializeLongPollResponse);
        }
コード例 #3
0
ファイル: TestViewModel.cs プロジェクト: RomanGL/OneVK-WP8.1
 private void VKLongPollService_ServiceStarted(IVKLongPollService sender, EventArgs args)
 {
     OnPropertyChanged(nameof(LongPollServiceState));
 }
コード例 #4
0
ファイル: TestViewModel.cs プロジェクト: RomanGL/OneVK-WP8.1
 private void VKLongPollService_ServiceStopped(IVKLongPollService sender, VKLongPollServiceStopReason args)
 {
     OnPropertyChanged(nameof(LongPollServiceState));
 }