Skip to content

Commit 8d27690

Browse files
committed
code_style: keep ux/code in a uniform style
1 parent 66f2aab commit 8d27690

File tree

4 files changed

+5
-12
lines changed

4 files changed

+5
-12
lines changed

src/Resources/Locales/en_US.axaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
<x:String x:Key="Text.Close" xml:space="preserve">CLOSE</x:String>
7878
<x:String x:Key="Text.CommitCM.CherryPick" xml:space="preserve">Cherry-Pick This Commit</x:String>
7979
<x:String x:Key="Text.CommitCM.CopySHA" xml:space="preserve">Copy SHA</x:String>
80-
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">Checkout commit${0}</x:String>
80+
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">Checkout Commit</x:String>
8181
<x:String x:Key="Text.CommitCM.Rebase" xml:space="preserve">Rebase${0}$to Here</x:String>
8282
<x:String x:Key="Text.CommitCM.Reset" xml:space="preserve">Reset${0}$to Here</x:String>
8383
<x:String x:Key="Text.CommitCM.Revert" xml:space="preserve">Revert Commit</x:String>

src/Resources/Locales/zh_CN.axaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@
7676
<x:String x:Key="Text.Clone.RemoteURL" xml:space="preserve">远程仓库 :</x:String>
7777
<x:String x:Key="Text.Close" xml:space="preserve">关闭</x:String>
7878
<x:String x:Key="Text.CommitCM.CherryPick" xml:space="preserve">挑选(cherry-pick)此提交</x:String>
79-
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">检出提交${0}</x:String>
79+
<x:String x:Key="Text.CommitCM.Checkout" xml:space="preserve">检出此提交</x:String>
8080
<x:String x:Key="Text.CommitCM.CopySHA" xml:space="preserve">复制提交指纹</x:String>
8181
<x:String x:Key="Text.CommitCM.Rebase" xml:space="preserve">变基(rebase)${0}$到此处</x:String>
8282
<x:String x:Key="Text.CommitCM.Reset" xml:space="preserve">重置(reset)${0}$到此处</x:String>

src/ViewModels/Histories.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -236,11 +236,12 @@ public ContextMenu MakeContextMenu()
236236
menu.Items.Add(reset);
237237

238238
var checkoutCommit = new MenuItem();
239-
checkoutCommit.Header = new Views.NameHighlightedTextBlock("CommitCM.Checkout", commit.SHA.Substring(0, 10));
239+
checkoutCommit.Header = App.Text("CommitCM.Checkout");
240240
checkoutCommit.Icon = App.CreateMenuIcon("Icons.Check");
241241
checkoutCommit.Click += (o, e) =>
242242
{
243-
_repo.CheckoutCommit(commit);
243+
if (PopupHost.CanCreatePopup())
244+
PopupHost.ShowPopup(new CheckoutCommit(_repo, commit));
244245
e.Handled = true;
245246
};
246247
menu.Items.Add(checkoutCommit);

src/ViewModels/Repository.cs

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -721,14 +721,6 @@ public void CheckoutLocalBranch(string branch)
721721
else
722722
PopupHost.ShowAndStartPopup(new Checkout(this, branch));
723723
}
724-
725-
public void CheckoutCommit(Models.Commit commit)
726-
{
727-
if (!PopupHost.CanCreatePopup())
728-
return;
729-
730-
PopupHost.ShowPopup(new CheckoutCommit(this, commit));
731-
}
732724

733725
public void DeleteMultipleBranches(List<Models.Branch> branches, bool isLocal)
734726
{

0 commit comments

Comments
 (0)