Skip to content

Commit 1c9a812

Browse files
committed
exactly match behavior of left sidebar
1 parent 3a662c0 commit 1c9a812

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/ViewModels/Histories.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -237,18 +237,18 @@ public void DoubleTapped(Models.Commit commit, Models.Decorator decorator = null
237237
{
238238
if (localBranch.IsCurrent)
239239
return;
240-
if (localBranch.TrackStatus.Behind.Count == 0)
241-
_repo.CheckoutBranch(localBranch);
242-
else if (localBranch.TrackStatus.Ahead.Count == 0)
240+
if (localBranch.TrackStatus.Ahead.Count > 0)
243241
{
244242
if (_repo.CanCreatePopup())
245-
_repo.ShowPopup(new CheckoutAndFastForward(_repo, localBranch, remoteBranch));
243+
_repo.ShowPopup(new CreateBranch(_repo, remoteBranch));
246244
}
247-
else
245+
else if (localBranch.TrackStatus.Behind.Count > 0)
248246
{
249247
if (_repo.CanCreatePopup())
250-
_repo.ShowPopup(new CreateBranch(_repo, remoteBranch));
248+
_repo.ShowPopup(new CheckoutAndFastForward(_repo, localBranch, remoteBranch));
251249
}
250+
else
251+
_repo.CheckoutBranch(localBranch);
252252
return;
253253
}
254254
}

0 commit comments

Comments
 (0)