• R/O
  • HTTP
  • SSH
  • HTTPS

TortoiseGitJp: Commit

TortoiseGit日本語言語ファイル作成


Commit MetaInfo

Revisiónb3e34065d421004d88d3f03fd428ee9f6498935c (tree)
Tiempo2010-01-19 22:22:09
AutorFrank Li <lznuaa@gmai...>
CommiterFrank Li

Log Message

Fixed issue #275: Load gitweb for 'Browse' button

Signed-off-by: Frank Li <lznuaa@gmail.com>

Cambiar Resumen

Diferencia incremental

Binary files a/src/Resources/TortoiseProcENG.rc and b/src/Resources/TortoiseProcENG.rc differ
--- a/src/TortoiseProc/CloneDlg.cpp
+++ b/src/TortoiseProc/CloneDlg.cpp
@@ -25,6 +25,7 @@ CCloneDlg::CCloneDlg(CWnd* pParent /*=NULL*/)
2525 m_strSVNTags = _T("tags");
2626 m_strSVNBranchs = _T("branches");
2727
28+ m_regBrowseUrl = CRegDWORD(_T("Software\\TortoiseGit\\TortoiseProc\\CloneBrowse"),0);
2829 m_nSVNFrom = 0;
2930 }
3031
@@ -37,6 +38,7 @@ void CCloneDlg::DoDataExchange(CDataExchange* pDX)
3738 CResizableStandAloneDialog::DoDataExchange(pDX);
3839 DDX_Control(pDX, IDC_URLCOMBO, m_URLCombo);
3940 DDX_Control(pDX, IDC_PUTTYKEYFILE, m_PuttyKeyCombo);
41+ DDX_Control(pDX, IDC_CLONE_BROWSE_URL, m_BrowseUrl);
4042 DDX_Text(pDX, IDC_CLONE_DIR, m_Directory);
4143 DDX_Check(pDX,IDC_PUTTYKEY_AUTOLOAD, m_bAutoloadPuttyKeyFile);
4244
@@ -89,6 +91,10 @@ BOOL CCloneDlg::OnInitDialog()
8991 if(window)
9092 SHAutoComplete(window->m_hWnd, SHACF_FILESYSTEM);
9193
94+ this->m_BrowseUrl.AddEntry(CString(_T("Dir...")));
95+ this->m_BrowseUrl.AddEntry(CString(_T("Web")));
96+ m_BrowseUrl.SetCurrentEntry(m_regBrowseUrl);
97+
9298 m_PuttyKeyCombo.SetPathHistory(TRUE);
9399 m_PuttyKeyCombo.LoadHistory(_T("Software\\TortoiseGit\\History\\puttykey"), _T("key"));
94100 m_PuttyKeyCombo.SetCurSel(0);
@@ -154,6 +160,18 @@ void CCloneDlg::OnBnClickedCloneBrowseUrl()
154160 CBrowseFolder browseFolder;
155161 browseFolder.m_style = BIF_EDITBOX | BIF_NEWDIALOGSTYLE | BIF_RETURNFSANCESTORS | BIF_RETURNONLYFSDIRS;
156162 CString strCloneDirectory;
163+
164+ int sel = this->m_BrowseUrl.GetCurrentEntry();
165+ this->m_regBrowseUrl = sel;
166+
167+ if( sel == 1 )
168+ {
169+ CString str;
170+ m_URLCombo.GetWindowText(str);
171+ ShellExecute(NULL, _T("open"), str, NULL,NULL, SW_SHOW);
172+ return ;
173+ }
174+
157175 this->m_URLCombo.GetWindowTextW(strCloneDirectory);
158176 if (browseFolder.Show(GetSafeHwnd(), strCloneDirectory) == CBrowseFolder::OK)
159177 {
--- a/src/TortoiseProc/CloneDlg.h
+++ b/src/TortoiseProc/CloneDlg.h
@@ -2,8 +2,8 @@
22
33 #include "StandAloneDlg.h"
44 #include "HistoryCombo.h"
5-
6-
5+#include "MenuButton.h"
6+#include "registry.h"
77
88 // CCloneDlg dialog
99
@@ -50,6 +50,9 @@ public:
5050 CString m_strSVNBranchs;
5151 int m_nSVNFrom;
5252
53+ CMenuButton m_BrowseUrl;
54+ CRegDWORD m_regBrowseUrl;
55+
5356 afx_msg void OnBnClickedPuttykeyfileBrowse();
5457 afx_msg void OnBnClickedPuttykeyAutoload();
5558 afx_msg void OnCbnSelchangeUrlcombo();
Show on old repository browser