Do not fetch after adding remote when settings dialog launches with remote as default...
[TortoiseGit.git] / src / TortoiseProc / Settings / SettingGitRemote.h
blobad0803cee14a89b359184cc37417098f94de1fa9
1 // TortoiseGit - a Windows shell extension for easy version control
3 // Copyright (C) 2008-2011 - TortoiseGit
5 // This program is free software; you can redistribute it and/or
6 // modify it under the terms of the GNU General Public License
7 // as published by the Free Software Foundation; either version 2
8 // of the License, or (at your option) any later version.
10 // This program is distributed in the hope that it will be useful,
11 // but WITHOUT ANY WARRANTY; without even the implied warranty of
12 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 // GNU General Public License for more details.
15 // You should have received a copy of the GNU General Public License
16 // along with this program; if not, write to the Free Software Foundation,
17 // 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19 #pragma once
20 #include "afxwin.h"
21 #include "SettingsPropPage.h"
22 #include "Tooltip.h"
23 #include "registry.h"
24 #include "afxwin.h"
26 // CSettingGitRemote dialog
27 class CSettingGitRemote : public ISettingsPropPage
29 DECLARE_DYNAMIC(CSettingGitRemote)
31 public:
32 enum
34 REMOTE_NAME =0x1,
35 REMOTE_URL =0x2,
36 REMOTE_PUTTYKEY =0x4,
38 CSettingGitRemote(CString cmdPath);
39 virtual ~CSettingGitRemote();
40 UINT GetIconID() {return IDI_GITREMOTE;}
41 // Dialog Data
42 enum { IDD = IDD_SETTINREMOTE };
44 bool m_bNoFetch;
46 protected:
47 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
49 DECLARE_MESSAGE_MAP()
51 afx_msg void OnBnClickedButtonBrowse();
52 afx_msg void OnBnClickedButtonAdd();
53 afx_msg void OnLbnSelchangeListRemote();
54 afx_msg void OnEnChangeEditRemote();
55 afx_msg void OnEnChangeEditUrl();
56 afx_msg void OnEnChangeEditPuttyKey();
57 afx_msg void OnBnClickedButtonRemove();
59 BOOL OnInitDialog();
60 BOOL OnApply();
62 BOOL IsRemoteExist(CString &remote);
64 void Save(CString key, CString value);
66 int m_ChangedMask;
68 CString m_cmdPath;
70 CListBox m_ctrlRemoteList;
71 CString m_strRemote;
72 CString m_strUrl;
74 CString m_strPuttyKeyfile;