@@ -516,7 +516,7 @@ private void OnTreeKeyDown(object _, KeyEventArgs e)
516
516
e . Handled = true ;
517
517
}
518
518
519
- private void OnDoubleTappedBranchNode ( object sender , TappedEventArgs _ )
519
+ private async void OnDoubleTappedBranchNode ( object sender , TappedEventArgs _ )
520
520
{
521
521
if ( sender is Grid { DataContext : ViewModels . BranchTreeNode node } )
522
522
{
@@ -526,7 +526,7 @@ private void OnDoubleTappedBranchNode(object sender, TappedEventArgs _)
526
526
return ;
527
527
528
528
if ( DataContext is ViewModels . Repository { Settings : not null } repo )
529
- repo . CheckoutBranch ( branch ) ;
529
+ await repo . CheckoutBranchAsync ( branch ) ;
530
530
}
531
531
else
532
532
{
@@ -606,10 +606,10 @@ private ContextMenu CreateContextMenuForLocalBranch(ViewModels.Repository repo,
606
606
fastForward . Header = App . Text ( "BranchCM.FastForward" , upstream . FriendlyName ) ;
607
607
fastForward . Icon = App . CreateMenuIcon ( "Icons.FastForward" ) ;
608
608
fastForward . IsEnabled = branch . TrackStatus . Ahead . Count == 0 && branch . TrackStatus . Behind . Count > 0 ;
609
- fastForward . Click += ( _ , e ) =>
609
+ fastForward . Click += async ( _ , e ) =>
610
610
{
611
611
if ( repo . CanCreatePopup ( ) )
612
- repo . ShowAndStartPopup ( new ViewModels . Merge ( repo , upstream , branch . Name , true ) ) ;
612
+ await repo . ShowAndStartPopupAsync ( new ViewModels . Merge ( repo , upstream , branch . Name , true ) ) ;
613
613
e . Handled = true ;
614
614
} ;
615
615
@@ -638,9 +638,9 @@ private ContextMenu CreateContextMenuForLocalBranch(ViewModels.Repository repo,
638
638
var checkout = new MenuItem ( ) ;
639
639
checkout . Header = App . Text ( "BranchCM.Checkout" , branch . Name ) ;
640
640
checkout . Icon = App . CreateMenuIcon ( "Icons.Check" ) ;
641
- checkout . Click += ( _ , e ) =>
641
+ checkout . Click += async ( _ , e ) =>
642
642
{
643
- repo . CheckoutBranch ( branch ) ;
643
+ await repo . CheckoutBranchAsync ( branch ) ;
644
644
e . Handled = true ;
645
645
} ;
646
646
menu . Items . Add ( checkout ) ;
@@ -654,10 +654,10 @@ private ContextMenu CreateContextMenuForLocalBranch(ViewModels.Repository repo,
654
654
fastForward . Header = App . Text ( "BranchCM.FastForward" , upstream . FriendlyName ) ;
655
655
fastForward . Icon = App . CreateMenuIcon ( "Icons.FastForward" ) ;
656
656
fastForward . IsEnabled = branch . TrackStatus . Ahead . Count == 0 && branch . TrackStatus . Behind . Count > 0 ;
657
- fastForward . Click += ( _ , e ) =>
657
+ fastForward . Click += async ( _ , e ) =>
658
658
{
659
659
if ( repo . CanCreatePopup ( ) )
660
- repo . ShowAndStartPopup ( new ViewModels . ResetWithoutCheckout ( repo , branch , upstream ) ) ;
660
+ await repo . ShowAndStartPopupAsync ( new ViewModels . ResetWithoutCheckout ( repo , branch , upstream ) ) ;
661
661
e . Handled = true ;
662
662
} ;
663
663
menu . Items . Add ( fastForward ) ;
@@ -666,10 +666,10 @@ private ContextMenu CreateContextMenuForLocalBranch(ViewModels.Repository repo,
666
666
fetchInto . Header = App . Text ( "BranchCM.FetchInto" , upstream . FriendlyName , branch . Name ) ;
667
667
fetchInto . Icon = App . CreateMenuIcon ( "Icons.Fetch" ) ;
668
668
fetchInto . IsEnabled = branch . TrackStatus . Ahead . Count == 0 ;
669
- fetchInto . Click += ( _ , e ) =>
669
+ fetchInto . Click += async ( _ , e ) =>
670
670
{
671
671
if ( repo . CanCreatePopup ( ) )
672
- repo . ShowAndStartPopup ( new ViewModels . FetchInto ( repo , branch , upstream ) ) ;
672
+ await repo . ShowAndStartPopupAsync ( new ViewModels . FetchInto ( repo , branch , upstream ) ) ;
673
673
e . Handled = true ;
674
674
} ;
675
675
@@ -898,10 +898,10 @@ private ContextMenu CreateContextMenuForRemote(ViewModels.Repository repo, Model
898
898
var prune = new MenuItem ( ) ;
899
899
prune . Header = App . Text ( "RemoteCM.Prune" ) ;
900
900
prune . Icon = App . CreateMenuIcon ( "Icons.Clean" ) ;
901
- prune . Click += ( _ , e ) =>
901
+ prune . Click += async ( _ , e ) =>
902
902
{
903
903
if ( repo . CanCreatePopup ( ) )
904
- repo . ShowAndStartPopup ( new ViewModels . PruneRemote ( repo , remote ) ) ;
904
+ await repo . ShowAndStartPopupAsync ( new ViewModels . PruneRemote ( repo , remote ) ) ;
905
905
e . Handled = true ;
906
906
} ;
907
907
@@ -952,9 +952,9 @@ public ContextMenu CreateContextMenuForRemoteBranch(ViewModels.Repository repo,
952
952
var checkout = new MenuItem ( ) ;
953
953
checkout . Header = App . Text ( "BranchCM.Checkout" , name ) ;
954
954
checkout . Icon = App . CreateMenuIcon ( "Icons.Check" ) ;
955
- checkout . Click += ( _ , e ) =>
955
+ checkout . Click += async ( _ , e ) =>
956
956
{
957
- repo . CheckoutBranch ( branch ) ;
957
+ await repo . CheckoutBranchAsync ( branch ) ;
958
958
e . Handled = true ;
959
959
} ;
960
960
menu . Items . Add ( checkout ) ;
@@ -1099,9 +1099,9 @@ private void TryToAddCustomActionsToBranchContextMenu(ViewModels.Repository repo
1099
1099
var item = new MenuItem ( ) ;
1100
1100
item . Icon = App . CreateMenuIcon ( "Icons.Action" ) ;
1101
1101
item . Header = label ;
1102
- item . Click += ( _ , e ) =>
1102
+ item . Click += async ( _ , e ) =>
1103
1103
{
1104
- repo . ExecCustomAction ( dup , branch ) ;
1104
+ await repo . ExecCustomActionAsync ( dup , branch ) ;
1105
1105
e . Handled = true ;
1106
1106
} ;
1107
1107
0 commit comments