From 6f196affcfc8237760f89df14ebf45ac9fe7a064 Mon Sep 17 00:00:00 2001 From: Sven Strickroth Date: Fri, 11 May 2012 20:02:55 +0200 Subject: [PATCH] Moved some more strings to resources Signed-off-by: Sven Strickroth --- src/Resources/TortoiseProcENG.rc | 44 +++++++++++++++++++++++ src/TortoiseProc/AppUtils.cpp | 46 +++++++++++++----------- src/TortoiseProc/Commands/SVNRebaseCommand.cpp | 4 +-- src/TortoiseProc/FileDiffDlg.cpp | 24 ++++++++----- src/TortoiseProc/SyncDlg.cpp | 50 +++++++++++++------------- src/TortoiseProc/resource.h | 38 ++++++++++++++++++++ 6 files changed, 150 insertions(+), 56 deletions(-) diff --git a/src/Resources/TortoiseProcENG.rc b/src/Resources/TortoiseProcENG.rc index 8408ac05f..a84df76cf 100644 --- a/src/Resources/TortoiseProcENG.rc +++ b/src/Resources/TortoiseProcENG.rc @@ -2451,7 +2451,15 @@ BEGIN IDS_SSL_PKCS12 "PKCS12" IDS_IMPORT_DEFAULTMSG "Initial import" IDS_LOG_COPYFROM "Copy from path" + IDS_PROC_SYNC_PUSHTAGS "Push ta&gs" + IDS_PROC_SYNC_PULL "&Pull" + IDS_PROC_SYNC_FETCH "Fetc&h" + IDS_PROC_SYNC_FETCHREBASE "Fetch&&Re&base" IDS_LOG_REVERT_CONFIRM "Do you really want to revert all changes in\n%s\nwhich were made in this revision? These changes will be reverted by reverse-merging the revision into your working copy." + IDS_PROC_SYNC_REMOTEUPDATE "Remote Update" + IDS_PROC_SYNC_CLEANUPSTALEBRANCHES "Cleanup stale remote banches" + IDS_PROC_SYNC_SUBKODULEUPDATE "Submodule Update" + IDS_PROC_SYNC_SUBKODULEINIT "Submodule Init" END STRINGTABLE @@ -2473,6 +2481,7 @@ BEGIN IDS_PROGRS_TITLEFIN "Finished!" IDS_PROGRS_TITLE_CHECKOUT "Checkout" IDS_PROGRS_TITLE_IMPORT "Import" + IDS_PROC_SYNC_SUBKODULESYNC "Submodule Sync" IDS_PROGRS_TITLE_COMMIT "Commit" IDS_PROGRS_TITLE_ADD "Add" IDS_PROGRS_TITLE_REVERT "Revert" @@ -3747,6 +3756,41 @@ BEGIN IDS_PROC_STASHFAILED "Stash failed!!!" IDS_PROC_STASHSUCCESS "Stash Success" IDS_PROC_NOUSERDATA "User name and email must be set before commit.\r\n Do you want to set these now?" + IDS_PROC_PREVIOUSVERSION "Previous Version" + IDS_PROC_REFINVALID """%"" is invalid." + IDS_IGNOREBUTTON "&Ignore" + IDS_PROC_STASHAPPLYFAILED "Stash Apply failed!!!" + IDS_PROC_FILEDIFF_VERSION2BASE "Version 2 (Base)" + IDS_PROC_FILEDIFF_VERSION1 "Version 1" + IDS_PROC_FILEDIFF_VERSION1NEWER "Version 1 (Commit Data New)" + IDS_PROC_FILEDIFF_VERSION2BASENEWER "Version 2 (Base) (Commit Date New)" + IDS_ERR_PAEGENTTIMEOUT "Failed waiting for pageant to finish loading key." + IDS_ERR_NOPATCHES "Not patches generated." + IDS_PROC_REQUESTPULL "Create pull &request" + IDS_ERR_PULLREUQESTFAILED "Failed to create pull-request." +END + +STRINGTABLE +BEGIN + IDS_PROC_REMOVEBRANCH "Remove &branch" + IDS_PROGS_TITLE_EDITNOTES "Edit Notes" + IDS_PROC_FAILEDSAVINGNOTES "Saving notes failed." + IDS_PROC_FASTFORWARD "Fast Forward" + IDS_PROC_EVERYTHINGUPDATED "Everything updated." + IDS_PROC_SYNC_PULLWRONGBRANCH + "Pull requires the selected local branch to be the current branch." + IDS_PROC_SYNC_REFRESHING "Refreshing..." + IDS_PROC_SYNC_COMMITSAHEAD "%d commits ahead ""%s""" + IDS_PROC_SYNC_WAINTINPUT "Waiting for input" + IDS_PROC_SYNC_PUSH_UNKNOWN + "Don't know what will push because you enter URL" + IDS_PROC_SYNC_PUSH_UNKNOWNBRANCH + "Don't know what will push because unknown branch ""%s""" + IDS_PROC_SYNC_INCOMMITS "In Commits" + IDS_PROC_SYNC_INCHANGELIST "In ChangeList" + IDS_PROC_SYNC_OUTCOMMITS "Out Commits" + IDS_PROC_SYNC_OUTCHANGELIST "Out ChangeList" + IDS_PROC_SYNC_PUSH "Pus&h" END #endif // Englisch (USA) resources diff --git a/src/TortoiseProc/AppUtils.cpp b/src/TortoiseProc/AppUtils.cpp index e8eac356e..978f58a43 100644 --- a/src/TortoiseProc/AppUtils.cpp +++ b/src/TortoiseProc/AppUtils.cpp @@ -638,7 +638,7 @@ bool CAppUtils::LaunchPAgent(CString *keyfile,CString * pRemote) if( i== 10*60*5) { - CMessageBox::Show(NULL, _T("Fail wait for pageant finish load key"),_T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_ERR_PAEGENTTIMEOUT, IDS_APPNAME, MB_OK | MB_ICONERROR); } ::DeleteFile(tempfile); return true; @@ -1136,7 +1136,7 @@ bool CAppUtils::GitReset(CString *CommitHash,int type) CTGitPath gitPath = g_Git.m_CurrentDir; if (gitPath.HasSubmodules() && dlg.m_ResetType == 2) - progress.m_PostCmdList.Add(_T("Update Submodules")); + progress.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_PROC_SUBMODULESUPDATE))); int ret = progress.DoModal(); if (gitPath.HasSubmodules() && dlg.m_ResetType == 2 && ret == IDC_PROGRESS_BUTTON1) @@ -1158,15 +1158,15 @@ void CAppUtils::DescribeFile(bool mode, bool base,CString &descript) { if(mode == FALSE) { - descript=_T("Deleted"); + descript = CString(MAKEINTRESOURCE(IDS_SVNACTION_DELETE)); return; } if(base) { - descript=_T("Modified"); + descript = CString(MAKEINTRESOURCE(IDS_SVNACTION_MODIFIED)); return; } - descript=_T("Created"); + descript = CString(MAKEINTRESOURCE(IDS_SVNACTION_ADD)); return; } @@ -1762,7 +1762,7 @@ bool CAppUtils::SendPatchMail(CString &cmd,CString &formatpatchoutput,bool autoc } else { - CMessageBox::Show(NULL, _T("Not patches generated."), _T("TortoiseGit"), MB_ICONINFORMATION); + CMessageBox::Show(NULL, IDS_ERR_NOPATCHES, IDS_APPNAME, MB_ICONINFORMATION); return true; } } @@ -1902,11 +1902,11 @@ bool CAppUtils::Fetch(CString remoteName, bool allowRebase, bool autoClose) progress.m_bAutoCloseOnSuccess = autoClose; - progress.m_PostCmdList.Add(_T("Show Log")); + progress.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_MENULOG))); if(!dlg.m_bRebase && !g_GitAdminDir.IsBareRepo(g_Git.m_CurrentDir)) { - progress.m_PostCmdList.Add(_T("&Rebase")); + progress.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_MENUREBASE))); } progress.m_GitCmd=cmd; @@ -1924,8 +1924,8 @@ bool CAppUtils::Fetch(CString remoteName, bool allowRebase, bool autoClose) while(1) { CRebaseDlg dlg; - dlg.m_PostButtonTexts.Add(_T("Email &Patch...")); - dlg.m_PostButtonTexts.Add(_T("Restart Rebase")); + dlg.m_PostButtonTexts.Add(CString(MAKEINTRESOURCE(IDS_MENUDESSENDMAIL))); + dlg.m_PostButtonTexts.Add(CString(MAKEINTRESOURCE(IDS_MENUREBASE))); int response = dlg.DoModal(); if(response == IDOK) { @@ -2025,8 +2025,8 @@ bool CAppUtils::Push(CString selectLocalBranch, bool autoClose) CProgressDlg progress; progress.m_bAutoCloseOnSuccess=autoClose; progress.m_GitCmd=cmd; - progress.m_PostCmdList.Add(_T("&Request pull")); - progress.m_PostCmdList.Add(_T("Re&Push")); + progress.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_PROC_REQUESTPULL))); + progress.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_MENUPUSH))); int ret = progress.DoModal(); if(!progress.m_GitStatus) @@ -2070,7 +2070,7 @@ bool CAppUtils::RequestPull(CString endrevision, CString repositoryUrl) CString tempFileName = GetTempFile(); if (g_Git.RunLogFile(cmd, tempFileName)) { - MessageBox(NULL, _T("Failed to create pull-request."), _T("TortoiseGit"), MB_OK); + CMessageBox::Show(NULL, IDS_ERR_PULLREUQESTFAILED, IDS_APPNAME, MB_OK); return false; } CAppUtils::LaunchAlternativeEditor(tempFileName); @@ -2245,7 +2245,9 @@ BOOL CAppUtils::SVNDCommit() } if(g_Git.SetConfigValue(_T("svn.rmdir"),gitSetting)) { - CMessageBox::Show(NULL,_T("Fail to set config"),_T("TortoiseGit"),MB_OK); + CString msg; + msg.Format(IDS_PROC_SAVECONFIGFAILED, _T("svn.rmdir"), gitSetting); + CMessageBox::Show(NULL, msg, _T("TortoiseGit"), MB_OK | MB_ICONERROR); } } } @@ -2344,9 +2346,9 @@ BOOL CAppUtils::Merge(CString *commit) Prodlg.m_GitCmd = cmd; if (dlg.m_bNoCommit) - Prodlg.m_PostCmdList.Add(_T("Commit")); + Prodlg.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_MENUCOMMIT))); else if (dlg.m_bIsBranch) - Prodlg.m_PostCmdList.Add(_T("Remove branch")); + Prodlg.m_PostCmdList.Add(CString(MAKEINTRESOURCE(IDS_PROC_REMOVEBRANCH))); int ret = Prodlg.DoModal(); @@ -2355,7 +2357,9 @@ BOOL CAppUtils::Merge(CString *commit) return Commit(_T(""), TRUE, CString(), CTGitPathList(), CTGitPathList(), true); else if (dlg.m_bIsBranch) { - if (CMessageBox::Show(NULL, _T("Do you really want to delete ") + dlg.m_VersionName + _T("?"), _T("TortoiseGit"), 2, IDI_QUESTION, _T("&Delete"), _T("&Abort")) == 1) + CString msg; + msg.Format(IDS_PROC_DELETEBRANCHTAG, dlg.m_VersionName); + if (CMessageBox::Show(NULL, msg, _T("TortoiseGit"), 2, IDI_QUESTION, CString(MAKEINTRESOURCE(IDS_DELETEBUTTON)), CString(MAKEINTRESOURCE(IDS_ABORTBUTTON))) == 1) { CString cmd, out; cmd.Format(_T("git.exe branch -D -- %s"), dlg.m_VersionName); @@ -2372,9 +2376,9 @@ BOOL CAppUtils::Merge(CString *commit) void CAppUtils::EditNote(GitRev *rev) { CInputDlg dlg; - dlg.m_sHintText=_T("Edit Notes"); + dlg.m_sHintText = CString(MAKEINTRESOURCE(IDS_PROGS_TITLE_EDITNOTES)); dlg.m_sInputText = rev->m_Notes; - dlg.m_sTitle=_T("Edit Notes"); + dlg.m_sTitle = CString(MAKEINTRESOURCE(IDS_PROGS_TITLE_EDITNOTES)); //dlg.m_pProjectProperties = &m_ProjectProperties; dlg.m_bUseLogWidth = true; if(dlg.DoModal() == IDOK) @@ -2392,7 +2396,7 @@ void CAppUtils::EditNote(GitRev *rev) { if (git_run_cmd("notes", CUnicodeUtils::GetMulti(cmd, CP_UTF8).GetBuffer())) { - CMessageBox::Show(NULL,_T("Edit Note Fail"), _T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_PROC_FAILEDSAVINGNOTES, IDS_APPNAME, MB_OK | MB_ICONERROR); } else @@ -2401,7 +2405,7 @@ void CAppUtils::EditNote(GitRev *rev) } }catch(...) { - CMessageBox::Show(NULL,_T("Edit Note Fail"), _T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_PROC_FAILEDSAVINGNOTES, IDS_APPNAME, MB_OK | MB_ICONERROR); } CFile::Remove(tempfile); diff --git a/src/TortoiseProc/Commands/SVNRebaseCommand.cpp b/src/TortoiseProc/Commands/SVNRebaseCommand.cpp index 8e1298a09..dedd0702d 100644 --- a/src/TortoiseProc/Commands/SVNRebaseCommand.cpp +++ b/src/TortoiseProc/Commands/SVNRebaseCommand.cpp @@ -95,7 +95,7 @@ bool SVNRebaseCommand::Execute() //everything updated if(UpStreamNewHash==HeadHash) { - CMessageBox::Show(NULL,_T("Everything Updated"),_T("TortoiseGit"),MB_OK); + CMessageBox::Show(NULL, IDS_PROC_EVERYTHINGUPDATED, IDS_APPNAME, MB_OK); if(isStash) askIfUserWantsToStashPop(); @@ -114,7 +114,7 @@ bool SVNRebaseCommand::Execute() return false; else { - MessageBox(NULL, _T("Fast Forward:\n") + progressReset.m_LogText, _T("TortoiseGit"), MB_OK); + MessageBox(NULL, CString(MAKEINTRESOURCE(IDS_PROC_FASTFORWARD)) + _T(":\n") + progressReset.m_LogText, _T("TortoiseGit"), MB_OK); if(isStash) askIfUserWantsToStashPop(); diff --git a/src/TortoiseProc/FileDiffDlg.cpp b/src/TortoiseProc/FileDiffDlg.cpp index 5288f9d5f..20ceb1ce9 100644 --- a/src/TortoiseProc/FileDiffDlg.cpp +++ b/src/TortoiseProc/FileDiffDlg.cpp @@ -154,7 +154,7 @@ void CFileDiffDlg::SetDiff(CTGitPath * path, GitRev rev1) } m_rev1 = rev1; m_rev2.m_CommitHash.Empty(); - m_rev2.GetSubject() = _T("Previous Version"); + m_rev2.GetSubject() = CString(MAKEINTRESOURCE(IDS_PROC_PREVIOUSVERSION)); //this->GetDlgItem()->EnableWindow(FALSE); } @@ -238,7 +238,11 @@ BOOL CFileDiffDlg::OnInitDialog() else { if(m_rev1.GetCommit(this->m_strRev1)) - this->m_FileListText+=this->m_strRev1 + _T(" is wrong"); + { + CString msg; + msg.Format(IDS_PROC_REFINVALID, this->m_strRev1); + this->m_FileListText += msg; + } this->m_ctrRev1Edit.SetWindowText(m_strRev1); } @@ -248,7 +252,11 @@ BOOL CFileDiffDlg::OnInitDialog() else { if(m_rev2.GetCommit(this->m_strRev2)) - this->m_FileListText+=this->m_strRev2 + _T(" is wrong"); + { + CString msg; + msg.Format(IDS_PROC_REFINVALID, this->m_strRev2); + this->m_FileListText += msg; + } this->m_ctrRev2Edit.SetWindowText(m_strRev2); } @@ -637,7 +645,7 @@ void CFileDiffDlg::OnContextMenu(CWnd* pWnd, CPoint point) { CString out; out.Format(IDS_STATUSLIST_CHECKOUTFILEFAILED, fd->GetGitPathString(), m_rev1.m_CommitHash.ToString(), filename); - if (CMessageBox::Show(NULL, out, _T("TortoiseGit"), 2, IDI_WARNING, _T("&Proceed"), _T("&Abort")) == 2) + if (CMessageBox::Show(NULL, out, _T("TortoiseGit"), 2, IDI_WARNING, CString(MAKEINTRESOURCE(IDS_IGNOREBUTTON)), CString(MAKEINTRESOURCE(IDS_ABORTBUTTON))) == 2) return; } } @@ -743,17 +751,17 @@ void CFileDiffDlg::SetURLLabels(int mask) CLoglistUtils::FormatDateAndTime(m_rev2.GetAuthorDate(), DATE_SHORTDATE, false) + _T(" ") + m_rev2.GetAuthorName()); } - this->GetDlgItem(IDC_REV2GROUP)->SetWindowText(_T("Version 2 (Base)")); - this->GetDlgItem(IDC_REV1GROUP)->SetWindowText(_T("Version 1")); + this->GetDlgItem(IDC_REV2GROUP)->SetWindowText(CString(MAKEINTRESOURCE(IDS_PROC_FILEDIFF_VERSION2BASE))); + this->GetDlgItem(IDC_REV1GROUP)->SetWindowText(CString(MAKEINTRESOURCE(IDS_PROC_FILEDIFF_VERSION1))); if( (mask&0x3) == 0x3) if(m_rev2.GetCommitterDate() > m_rev1.GetCommitterDate()) { - this->GetDlgItem(IDC_REV2GROUP)->SetWindowText(_T("Version 2 (Base) (Commit Date New)")); + this->GetDlgItem(IDC_REV2GROUP)->SetWindowText(CString(MAKEINTRESOURCE(IDS_PROC_FILEDIFF_VERSION2BASENEWER))); } else { - this->GetDlgItem(IDC_REV1GROUP)->SetWindowText(_T("Version 1 (Commit Data New)")); + this->GetDlgItem(IDC_REV1GROUP)->SetWindowText(CString(MAKEINTRESOURCE(IDS_PROC_FILEDIFF_VERSION1NEWER))); } } diff --git a/src/TortoiseProc/SyncDlg.cpp b/src/TortoiseProc/SyncDlg.cpp index 6370a7343..b2ea8d93a 100644 --- a/src/TortoiseProc/SyncDlg.cpp +++ b/src/TortoiseProc/SyncDlg.cpp @@ -114,14 +114,14 @@ void CSyncDlg::OnBnClickedButtonPull() { if( g_Git.GetHash(this->m_strLocalBranch) != m_oldHash) { - CMessageBox::Show(NULL,_T("Pull require local branch must be current branch"),_T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_PROC_SYNC_PULLWRONGBRANCH, IDS_APPNAME, MB_OK | MB_ICONERROR); return; } } if(this->m_strURL.IsEmpty()) { - CMessageBox::Show(NULL,_T("URL can't Empty"),_T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_PROC_GITCONFIG_URLEMPTY, IDS_APPNAME, MB_OK | MB_ICONERROR); return; } @@ -324,7 +324,7 @@ void CSyncDlg::PullComplete() if(newhash == this->m_oldHash) { this->m_ctrlTabCtrl.ShowTab(IDC_IN_CHANGELIST-1,false); - this->m_InLogList.ShowText(_T("No commits get after pull")); + this->m_InLogList.ShowText(CString(MAKEINTRESOURCE(IDS_UPTODATE))); this->m_ctrlTabCtrl.ShowTab(IDC_IN_LOGLIST-1,true); } else @@ -384,7 +384,7 @@ void CSyncDlg::OnBnClickedButtonPush() if(this->m_strURL.IsEmpty()) { - CMessageBox::Show(NULL,_T("URL can't Empty"),_T("TortoiseGit"),MB_OK|MB_ICONERROR); + CMessageBox::Show(NULL, IDS_PROC_GITCONFIG_URLEMPTY, IDS_APPNAME, MB_OK | MB_ICONERROR); return; } @@ -635,7 +635,7 @@ BOOL CSyncDlg::OnInitDialog() CAppUtils::CreateFontForLogs(m_logFont); //GetDlgItem(IDC_CMD_LOG)->SetFont(&m_logFont); m_ctrlCmdOut.SetFont(&m_logFont); - m_ctrlTabCtrl.InsertTab(&m_ctrlCmdOut,_T("Log"),-1); + m_ctrlTabCtrl.InsertTab(&m_ctrlCmdOut, CString(MAKEINTRESOURCE(IDS_LOG)), -1); //m_ctrlCmdOut.ReplaceSel(_T("Hello")); @@ -648,7 +648,7 @@ BOOL CSyncDlg::OnInitDialog() return FALSE; // fail to create } - m_ctrlTabCtrl.InsertTab(&m_InLogList,_T("In Commits"),-1); + m_ctrlTabCtrl.InsertTab(&m_InLogList, CString(MAKEINTRESOURCE(IDS_PROC_SYNC_INCOMMITS)), -1); m_InLogList.m_ColumnRegKey=_T("SyncIn"); m_InLogList.InsertGitColumn(); @@ -661,7 +661,7 @@ BOOL CSyncDlg::OnInitDialog() TRACE0("Failed to create output change files window\n"); return FALSE; // fail to create } - m_ctrlTabCtrl.InsertTab(&m_InChangeFileList,_T("In ChangeList"),-1); + m_ctrlTabCtrl.InsertTab(&m_InChangeFileList, CString(MAKEINTRESOURCE(IDS_PROC_SYNC_INCHANGELIST)), -1); m_InChangeFileList.Init(GITSLC_COLEXT | GITSLC_COLSTATUS |GITSLC_COLADD|GITSLC_COLDEL , _T("OutSyncDlg"), (CGitStatusListCtrl::GetContextMenuBit(CGitStatusListCtrl::IDGITLC_COMPARETWO)| @@ -695,7 +695,7 @@ BOOL CSyncDlg::OnInitDialog() } - m_ctrlTabCtrl.InsertTab(&m_OutLogList,_T("Out Commits"),-1); + m_ctrlTabCtrl.InsertTab(&m_OutLogList, CString(MAKEINTRESOURCE(IDS_PROC_SYNC_OUTCOMMITS)), -1); m_OutLogList.m_ColumnRegKey = _T("SyncOut"); m_OutLogList.InsertGitColumn(); @@ -709,7 +709,7 @@ BOOL CSyncDlg::OnInitDialog() TRACE0("Failed to create output change files window\n"); return FALSE; // fail to create } - m_ctrlTabCtrl.InsertTab(&m_OutChangeFileList,_T("Out ChangeList"),-1); + m_ctrlTabCtrl.InsertTab(&m_OutChangeFileList, CString(MAKEINTRESOURCE(IDS_PROC_SYNC_OUTCHANGELIST)), -1); m_OutChangeFileList.Init(GITSLC_COLEXT | GITSLC_COLSTATUS |GITSLC_COLADD|GITSLC_COLDEL , _T("OutSyncDlg"), (CGitStatusListCtrl::GetContextMenuBit(CGitStatusListCtrl::IDGITLC_COMPARETWO)| @@ -750,19 +750,19 @@ BOOL CSyncDlg::OnInitDialog() this->AddOthersToAnchor(); - this->m_ctrlPush.AddEntry(CString(_T("Pus&h"))); - this->m_ctrlPush.AddEntry(CString(_T("Push ta&gs"))); + this->m_ctrlPush.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_PUSH))); + this->m_ctrlPush.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_PUSHTAGS))); ///this->m_ctrlPush.AddEntry(CString(_T("Push All"))); - this->m_ctrlPull.AddEntry(CString(_T("&Pull"))); - this->m_ctrlPull.AddEntry(CString(_T("Fetc&h"))); - this->m_ctrlPull.AddEntry(CString(_T("Fetch&&Re&base"))); - this->m_ctrlPull.AddEntry(CString(_T("Remote Update"))); - this->m_ctrlPull.AddEntry(CString(_T("Cleanup stale remote banches"))); + this->m_ctrlPull.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_PULL))); + this->m_ctrlPull.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_FETCH))); + this->m_ctrlPull.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_FETCHREBASE))); + this->m_ctrlPull.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_REMOTEUPDATE))); + this->m_ctrlPull.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_CLEANUPSTALEBRANCHES))); - this->m_ctrlSubmodule.AddEntry(CString(_T("Submodule Update"))); - this->m_ctrlSubmodule.AddEntry(CString(_T("Submodule Init"))); - this->m_ctrlSubmodule.AddEntry(CString(_T("Submodule Sync"))); + this->m_ctrlSubmodule.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_SUBKODULEUPDATE))); + this->m_ctrlSubmodule.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_SUBKODULEINIT))); + this->m_ctrlSubmodule.AddEntry(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_SUBKODULESYNC))); WorkingDir.Replace(_T(':'),_T('_')); @@ -848,7 +848,7 @@ void CSyncDlg::Refresh() this->m_ctrlRemoteBranch.AddString(remote); this->m_ctrlURL.AddString(url); - m_OutLogList.ShowText(_T("Refresh ...")); + m_OutLogList.ShowText(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_REFRESHING))); this->FetchOutList(true); theApp.DoWaitCursor(-1); } @@ -902,7 +902,7 @@ void CSyncDlg::FetchOutList(bool force) if(IsURL()) { CString str; - str=_T("Don't know what will push because you enter URL"); + str.LoadString(IDS_PROC_SYNC_PUSH_UNKNOWN); m_OutLogList.ShowText(str); this->m_ctrlTabCtrl.ShowTab(m_OutChangeFileList.GetDlgCtrlID()-1,FALSE); m_OutLocalBranch.Empty(); @@ -915,7 +915,7 @@ void CSyncDlg::FetchOutList(bool force) else if(g_Git.GetHash(remotebranch).IsEmpty()) { CString str; - str.Format(_T("Don't know what will push because unknown \"%s\""),remotebranch); + str.Format(IDS_PROC_SYNC_PUSH_UNKNOWNBRANCH, remotebranch); m_OutLogList.ShowText(str); this->m_ctrlTabCtrl.ShowTab(m_OutChangeFileList.GetDlgCtrlID()-1,FALSE); m_OutLocalBranch.Empty(); @@ -938,7 +938,7 @@ void CSyncDlg::FetchOutList(bool force) CString str; if(m_OutLogList.GetItemCount() == 0) { - str.Format(_T("No commits ahead \"%s\""),remotebranch); + str.Format(IDS_PROC_SYNC_COMMITSAHEAD, 0, remotebranch); m_OutLogList.ShowText(str); this->m_ctrlStatus.SetWindowText(str); this->m_ctrlTabCtrl.ShowTab(m_OutChangeFileList.GetDlgCtrlID()-1,FALSE); @@ -946,7 +946,7 @@ void CSyncDlg::FetchOutList(bool force) } else { - str.Format(_T("%d commits ahead \"%s\""),m_OutLogList.GetItemCount(),remotebranch); + str.Format(IDS_PROC_SYNC_COMMITSAHEAD, m_OutLogList.GetItemCount(), remotebranch); this->m_ctrlStatus.SetWindowText(str); AddDiffFileList(&m_OutChangeFileList,&m_arOutChangeList,localbranch,remotebranch); @@ -973,7 +973,7 @@ bool CSyncDlg::IsURL() void CSyncDlg::OnCbnEditchangeComboboxex() { SetTimer(IDT_INPUT, 1000, NULL); - this->m_OutLogList.ShowText(_T("Wait for input")); + this->m_OutLogList.ShowText(CString(MAKEINTRESOURCE(IDS_PROC_SYNC_WAINTINPUT))); //this->FetchOutList(); } diff --git a/src/TortoiseProc/resource.h b/src/TortoiseProc/resource.h index 144860930..5a551df31 100644 --- a/src/TortoiseProc/resource.h +++ b/src/TortoiseProc/resource.h @@ -428,17 +428,29 @@ #define IDS_PROC_STASHSUCCESS 1138 #define IDS_PROC_NOUSERDATA 1139 #define IDC_COMMITSEACHWEEKAVG 1140 +#define IDS_PROC_PREVIOUSVERSION 1140 #define IDC_COMMITSEACHWEEKMIN 1141 +#define IDS_PROC_REFINVALID 1141 #define IDC_COMMITSEACHWEEKMAX 1142 +#define IDS_IGNOREBUTTON 1142 #define IDC_MOSTACTIVEAUTHORAVG 1143 +#define IDS_PROC_STASHAPPLYFAILED 1143 #define IDC_MOSTACTIVEAUTHORMIN 1144 +#define IDS_PROC_FILEDIFF_VERSION2BASE 1144 #define IDC_MOSTACTIVEAUTHORMAX 1145 +#define IDS_PROC_FILEDIFF_VERSION1 1145 #define IDC_LEASTACTIVEAUTHORAVG 1146 +#define IDS_PROC_FILEDIFF_VERSION1NEWER 1146 #define IDC_LEASTACTIVEAUTHORMIN 1147 +#define IDS_PROC_FILEDIFF_VERSION2BASENEWER 1147 #define IDC_LEASTACTIVEAUTHORMAX 1148 +#define IDS_ERR_PAEGENTTIMEOUT 1148 #define IDC_FILECHANGESEACHWEEKAVG 1149 +#define IDS_ERR_NOPATCHES 1149 #define IDC_FILECHANGESEACHWEEKMIN 1150 +#define IDS_PROC_REQUESTPULL 1150 #define IDC_FILECHANGESEACHWEEKMAX 1151 +#define IDS_ERR_PULLREUQESTFAILED 1151 #define IDS_MSGBOX_HELP 1152 #define IDS_MSGBOX_DONOTSHOWAGAIN 1153 #define IDS_MSGBOX_ABORT 1154 @@ -493,15 +505,31 @@ #define IDC_COPYWC 1183 #define IDS_ERR_INVALIDPATH 1183 #define IDC_AUTOCOMPLETION 1184 +#define IDS_PROC_REMOVEBRANCH 1184 #define IDC_COPYREV 1185 +#define IDS_PROGS_TITLE_EDITNOTES 1185 #define IDC_COPYREVTEXT 1186 +#define IDS_PROC_FAILEDSAVINGNOTES 1186 #define IDC_BROWSEFROM 1187 +#define IDS_PROC_FASTFORWARD 1187 +#define IDS_PROC_EVERYTHINGUPDATED 1188 +#define IDS_PROC_SYNC_PULLWRONGBRANCH 1189 +#define IDS_PROC_SYNC_REFRESHING 1190 #define IDC_SPLITTERTOP 1191 +#define IDS_PROC_SYNC_COMMITSAHEAD 1191 #define IDC_SPLITTERBOTTOM 1192 +#define IDS_PROC_SYNC_WAINTINPUT 1192 +#define IDS_PROC_SYNC_PUSH_UNKNOWN 1193 #define IDC_SEARCHEDIT 1194 +#define IDS_PROC_SYNC_PUSH_UNKNOWNBRANCH 1194 +#define IDS_PROC_SYNC_INCOMMITS 1195 #define IDC_FILTERICON 1196 +#define IDS_PROC_SYNC_INCHANGELIST 1196 +#define IDS_PROC_SYNC_OUTCOMMITS 1197 #define IDC_DATETO 1198 +#define IDS_PROC_SYNC_OUTCHANGELIST 1198 #define IDC_DATEFROM 1199 +#define IDS_PROC_SYNC_PUSH 1199 #define IDS_SSL_CERTIFICATETYPE 1200 #define IDC_FROMLABEL 1200 #define IDS_SSL_ACCEPTQUESTION 1201 @@ -513,11 +541,19 @@ #define IDS_IMPORT_DEFAULTMSG 1205 #define IDS_LOG_COPYFROM 1206 #define IDC_CHECKBOX 1207 +#define IDS_PROC_SYNC_PUSHTAGS 1207 #define IDC_SHOWWHOLEPROJECT 1208 +#define IDS_PROC_SYNC_PULL 1208 #define IDC_SHOWUNMODIFIED 1209 +#define IDS_PROC_SYNC_FETCH 1209 +#define IDS_PROC_SYNC_FETCHREBASE 1210 #define IDS_LOG_REVERT_CONFIRM 1211 +#define IDS_PROC_SYNC_REMOTEUPDATE 1212 +#define IDS_PROC_SYNC_CLEANUPSTALEBRANCHES 1213 #define IDC_OLDAPILOGS 1214 +#define IDS_PROC_SYNC_SUBKODULEUPDATE 1214 #define IDC_CHECKNEWERBUTTON 1215 +#define IDS_PROC_SYNC_SUBKODULEINIT 1215 #define IDS_LOG_POPUP_COPY 1216 #define IDC_CHECKNEWERBUTTON2 1216 #define IDC_MSYSGIT_CHECK 1216 @@ -540,6 +576,8 @@ #define IDC_WCPATHLABEL 1226 #define IDS_PROGRS_TITLE_UPDATE 1227 #define IDC_REPOCHECK 1227 +#define IDS_STRING1227 1227 +#define IDS_PROC_SYNC_SUBKODULESYNC 1227 #define IDS_PROGRS_TITLE_COMMIT 1228 #define IDS_PROGRS_TITLE_ADD 1229 #define IDC_HIDEPATHS 1229 -- 2.11.4.GIT