mirror of
https://github.com/sourcegit-scm/sourcegit
synced 2025-06-21 02:15:00 +00:00
exactly match behavior of left sidebar
This commit is contained in:
parent
3a662c0f40
commit
1c9a812745
1 changed files with 7 additions and 7 deletions
|
@ -237,18 +237,18 @@ namespace SourceGit.ViewModels
|
||||||
{
|
{
|
||||||
if (localBranch.IsCurrent)
|
if (localBranch.IsCurrent)
|
||||||
return;
|
return;
|
||||||
if (localBranch.TrackStatus.Behind.Count == 0)
|
if (localBranch.TrackStatus.Ahead.Count > 0)
|
||||||
_repo.CheckoutBranch(localBranch);
|
{
|
||||||
else if (localBranch.TrackStatus.Ahead.Count == 0)
|
if (_repo.CanCreatePopup())
|
||||||
|
_repo.ShowPopup(new CreateBranch(_repo, remoteBranch));
|
||||||
|
}
|
||||||
|
else if (localBranch.TrackStatus.Behind.Count > 0)
|
||||||
{
|
{
|
||||||
if (_repo.CanCreatePopup())
|
if (_repo.CanCreatePopup())
|
||||||
_repo.ShowPopup(new CheckoutAndFastForward(_repo, localBranch, remoteBranch));
|
_repo.ShowPopup(new CheckoutAndFastForward(_repo, localBranch, remoteBranch));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
_repo.CheckoutBranch(localBranch);
|
||||||
if (_repo.CanCreatePopup())
|
|
||||||
_repo.ShowPopup(new CreateBranch(_repo, remoteBranch));
|
|
||||||
}
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue