コード例 #1
0
 private async void GoToNextPage(object sender, ExecuteEventArgs args)
 {
     int index = this.group.Items.IndexOf(this.viewmodel) + 1;
     this.viewmodel = this.group.Items[index] as ArticleDataItem;
     await this.InvokeAndNotifyOnError(this.viewmodel.OnSelectedAsync(this, this.progress));
     NotifyAppBarCommands();
 }
コード例 #2
0
ファイル: PivotView.xaml.cs プロジェクト: jarkkom/awfuldotnet
 private async void OnRefreshCommandExecuteRaised(object sender, ExecuteEventArgs args)
 {
     var pivotItem = this.mainPivot.SelectedItem as FrameworkElement;
     var viewmodel = pivotItem.DataContext as IContentViewModel;
     if (viewmodel != null)
         await viewmodel.OnRefreshAsync(this, this.Progress);
 }
コード例 #3
0
ファイル: ListView.xaml.cs プロジェクト: jarkkom/awfuldotnet
 private async void OnRefreshCommandExecute(object sender, ExecuteEventArgs args)
 {
     await this.viewmodel.OnRefreshAsync(this, this.Progress);
     NotifyCommands();
 }
コード例 #4
0
ファイル: PivotView.xaml.cs プロジェクト: jarkkom/awfuldotnet
 private void OnLogoutCommandExecuted(object sender, ExecuteEventArgs args)
 {
     var response = MessageBox.Show("Are you sure you want to logout?", "Logout?", MessageBoxButton.OKCancel);
     if (response == MessageBoxResult.OK)
     {
         App.UserContext.Logout(new WPSettingsModel());
         MessageBox.Show("Restart the application to complete.", "Logout Complete.", MessageBoxButton.OK);
     }
 }