OSDN Git Service

Remove autoload option at setting dialog
authorFrank Li <lznuaa@gmail.com>
Thu, 2 Apr 2009 09:12:00 +0000 (17:12 +0800)
committerFrank Li <lznuaa@gmail.com>
Thu, 2 Apr 2009 09:12:00 +0000 (17:12 +0800)
Signed-off-by: Frank Li <lznuaa@gmail.com>
src/Resources/TortoiseProcENG.rc
src/TortoiseProc/Settings/SettingGitRemote.cpp
src/TortoiseProc/Settings/SettingGitRemote.h

index 67ce23f..0eacb1d 100644 (file)
Binary files a/src/Resources/TortoiseProcENG.rc and b/src/Resources/TortoiseProcENG.rc differ
index 51894a0..22b47c4 100644 (file)
@@ -33,7 +33,6 @@ void CSettingGitRemote::DoDataExchange(CDataExchange* pDX)
     DDX_Control(pDX, IDC_LIST_REMOTE, m_ctrlRemoteList);\r
     DDX_Text(pDX, IDC_EDIT_REMOTE, m_strRemote);\r
     DDX_Text(pDX, IDC_EDIT_URL, m_strUrl);\r
     DDX_Control(pDX, IDC_LIST_REMOTE, m_ctrlRemoteList);\r
     DDX_Text(pDX, IDC_EDIT_REMOTE, m_strRemote);\r
     DDX_Text(pDX, IDC_EDIT_URL, m_strUrl);\r
-    DDX_Control(pDX, IDC_CHECK_ISAUTOLOADPUTTYKEY, m_bAutoLoad);\r
     DDX_Text(pDX, IDC_EDIT_PUTTY_KEY, m_strPuttyKeyfile);\r
 }\r
 \r
     DDX_Text(pDX, IDC_EDIT_PUTTY_KEY, m_strPuttyKeyfile);\r
 }\r
 \r
@@ -44,7 +43,6 @@ BEGIN_MESSAGE_MAP(CSettingGitRemote, CPropertyPage)
     ON_LBN_SELCHANGE(IDC_LIST_REMOTE, &CSettingGitRemote::OnLbnSelchangeListRemote)\r
     ON_EN_CHANGE(IDC_EDIT_REMOTE, &CSettingGitRemote::OnEnChangeEditRemote)\r
     ON_EN_CHANGE(IDC_EDIT_URL, &CSettingGitRemote::OnEnChangeEditUrl)\r
     ON_LBN_SELCHANGE(IDC_LIST_REMOTE, &CSettingGitRemote::OnLbnSelchangeListRemote)\r
     ON_EN_CHANGE(IDC_EDIT_REMOTE, &CSettingGitRemote::OnEnChangeEditRemote)\r
     ON_EN_CHANGE(IDC_EDIT_URL, &CSettingGitRemote::OnEnChangeEditUrl)\r
-    ON_BN_CLICKED(IDC_CHECK_ISAUTOLOADPUTTYKEY, &CSettingGitRemote::OnBnClickedCheckIsautoloadputtykey)\r
     ON_EN_CHANGE(IDC_EDIT_PUTTY_KEY, &CSettingGitRemote::OnEnChangeEditPuttyKey)\r
 END_MESSAGE_MAP()\r
 \r
     ON_EN_CHANGE(IDC_EDIT_PUTTY_KEY, &CSettingGitRemote::OnEnChangeEditPuttyKey)\r
 END_MESSAGE_MAP()\r
 \r
@@ -108,7 +106,6 @@ void CSettingGitRemote::OnBnClickedButtonAdd()
        this->m_strRemote.Empty();\r
        this->m_strUrl.Empty();\r
        this->m_strPuttyKeyfile.Empty();\r
        this->m_strRemote.Empty();\r
        this->m_strUrl.Empty();\r
        this->m_strPuttyKeyfile.Empty();\r
-       this->m_bAutoLoad.SetCheck(false);\r
        this->UpdateData(FALSE);\r
        this->GetDlgItem(IDC_EDIT_REMOTE)->EnableWindow(TRUE);\r
        this->m_ChangedMask |= REMOTE_NAME;\r
        this->UpdateData(FALSE);\r
        this->GetDlgItem(IDC_EDIT_REMOTE)->EnableWindow(TRUE);\r
        this->m_ChangedMask |= REMOTE_NAME;\r
@@ -164,22 +161,6 @@ void CSettingGitRemote::OnLbnSelchangeListRemote()
        m_strPuttyKeyfile = m_strPuttyKeyfile.Tokenize(_T("\n"),start);\r
        \r
 \r
        m_strPuttyKeyfile = m_strPuttyKeyfile.Tokenize(_T("\n"),start);\r
        \r
 \r
-       cmd.Format(_T("git.exe config remote.%s.puttykeyautoload"),remote);\r
-       CString autoload;\r
-       if( g_Git.Run(cmd,&autoload,CP_ACP) )\r
-       {\r
-               //CMessageBox::Show(NULL,output,_T("TortoiseGit"),MB_OK|MB_ICONERROR);\r
-               //return;\r
-       }\r
-\r
-       start=0;\r
-       autoload = autoload.Tokenize(_T("\n"),start);\r
-       m_bAutoLoad.SetCheck(false);\r
-       if( autoload == _T("true"))\r
-       {\r
-               m_bAutoLoad.SetCheck(true);\r
-       }\r
-       \r
        m_ChangedMask=0;\r
 \r
        GetDlgItem(IDC_BUTTON_ADD)->EnableWindow(TRUE);\r
        m_ChangedMask=0;\r
 \r
        GetDlgItem(IDC_BUTTON_ADD)->EnableWindow(TRUE);\r
@@ -213,13 +194,6 @@ void CSettingGitRemote::OnEnChangeEditUrl()
        this->SetModified();\r
 }\r
 \r
        this->SetModified();\r
 }\r
 \r
-void CSettingGitRemote::OnBnClickedCheckIsautoloadputtykey()\r
-{\r
-    // TODO: Add your control notification handler code here\r
-       m_ChangedMask|=REMOTE_AUTOLOAD;\r
-       this->SetModified();\r
-}\r
-\r
 void CSettingGitRemote::OnEnChangeEditPuttyKey()\r
 {\r
     // TODO:  If this is a RICHEDIT control, the control will not\r
 void CSettingGitRemote::OnEnChangeEditPuttyKey()\r
 {\r
     // TODO:  If this is a RICHEDIT control, the control will not\r
@@ -274,10 +248,6 @@ BOOL CSettingGitRemote::OnApply()
                Save(_T("puttykey"),this->m_strPuttyKeyfile);\r
        }\r
 \r
                Save(_T("puttykey"),this->m_strPuttyKeyfile);\r
        }\r
 \r
-       if(m_ChangedMask & REMOTE_AUTOLOAD)\r
-       {\r
-               Save(_T("puttykeyautoload"),this->m_bAutoLoad.GetCheck()?_T("true"):_T("false"));\r
-       }\r
        this->GetDlgItem(IDC_EDIT_REMOTE)->EnableWindow(FALSE);\r
     SetModified(FALSE);\r
 \r
        this->GetDlgItem(IDC_EDIT_REMOTE)->EnableWindow(FALSE);\r
     SetModified(FALSE);\r
 \r
index f8a4270..5890346 100644 (file)
@@ -16,7 +16,6 @@ public:
                REMOTE_NAME             =0x1,\r
                REMOTE_URL              =0x2,\r
                REMOTE_PUTTYKEY =0x4,\r
                REMOTE_NAME             =0x1,\r
                REMOTE_URL              =0x2,\r
                REMOTE_PUTTYKEY =0x4,\r
-               REMOTE_AUTOLOAD =0x8,\r
        };\r
        CSettingGitRemote();\r
        virtual ~CSettingGitRemote();\r
        };\r
        CSettingGitRemote();\r
        virtual ~CSettingGitRemote();\r
@@ -42,13 +41,12 @@ public:
     CListBox m_ctrlRemoteList;\r
     CString m_strRemote;\r
     CString m_strUrl;\r
     CListBox m_ctrlRemoteList;\r
     CString m_strRemote;\r
     CString m_strUrl;\r
-    CButton m_bAutoLoad;\r
+    \r
     CString m_strPuttyKeyfile;\r
     afx_msg void OnBnClickedButtonBrowse();\r
     afx_msg void OnBnClickedButtonAdd();\r
     afx_msg void OnLbnSelchangeListRemote();\r
     afx_msg void OnEnChangeEditRemote();\r
     afx_msg void OnEnChangeEditUrl();\r
     CString m_strPuttyKeyfile;\r
     afx_msg void OnBnClickedButtonBrowse();\r
     afx_msg void OnBnClickedButtonAdd();\r
     afx_msg void OnLbnSelchangeListRemote();\r
     afx_msg void OnEnChangeEditRemote();\r
     afx_msg void OnEnChangeEditUrl();\r
-    afx_msg void OnBnClickedCheckIsautoloadputtykey();\r
     afx_msg void OnEnChangeEditPuttyKey();\r
 };\r
     afx_msg void OnEnChangeEditPuttyKey();\r
 };\r