Call CGit::DeleteRemoteRefs() to delete remote tags
[TortoiseGit.git] / src / TortoiseProc / FindDlg.h
blob8e3dc56f8d9e80545d26ac12bfddeaffdc867245
1 // TortoiseGit - a Windows shell extension for easy version control
3 // Copyright (C) 2011-2013 - 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.
20 #pragma once
22 #include "HistoryCombo.h"
23 #include "afxcmn.h"
24 #include "afxwin.h"
25 #include "StandAloneDlg.h"
26 #include "LoglistCommonResource.h"
27 #include "registry.h"
29 // CFindDlg dialog
31 #define IDT_FILTER 101
33 class CFindDlg : public CResizableStandAloneDialog
35 DECLARE_DYNAMIC(CFindDlg)
37 public:
38 CFindDlg(CWnd* pParent = NULL); // standard constructor
39 virtual ~CFindDlg();
40 void Create(CWnd * pParent = NULL) {m_pParent = pParent; CDialog::Create(IDD, pParent);ShowWindow(SW_SHOW);UpdateWindow();}
42 bool IsTerminating() {return m_bTerminating;}
43 bool FindNext() {return m_bFindNext;}
44 bool MatchCase() {return !!m_bMatchCase;}
45 bool WholeWord() {return !!m_bWholeWord;}
46 bool Regex() {return !!m_bRegex;}
47 bool IsRef() {return !!m_bIsRef;}
48 CString GetFindString() {return m_FindString;}
49 void SetFindString(const CString& str) { if (!str.IsEmpty()) { m_FindCombo.SetWindowText(str); } }
51 // Dialog Data
52 enum { IDD = IDD_FIND };
54 protected:
55 virtual void DoDataExchange(CDataExchange* pDX); // DDX/DDV support
56 virtual void OnCancel();
57 virtual void PostNcDestroy();
58 virtual void OnOK();
59 virtual BOOL OnInitDialog();
60 afx_msg void OnCbnEditchangeFindcombo();
62 DECLARE_MESSAGE_MAP()
64 UINT m_FindMsg;
65 bool m_bTerminating;
66 bool m_bFindNext;
67 BOOL m_bMatchCase;
68 BOOL m_bLimitToDiffs;
69 BOOL m_bWholeWord;
70 BOOL m_bRegex;
71 bool m_bIsRef;
72 CHistoryCombo m_FindCombo;
73 CString m_FindString;
74 CWnd *m_pParent;
75 STRING_VECTOR m_RefList;
76 CRegDWORD m_regMatchCase;
77 CRegDWORD m_regWholeWord;
78 CRegDWORD m_regRegex;
80 void AddToList();
82 public:
83 CListCtrl m_ctrlRefList;
84 CEdit m_ctrlFilter;
85 afx_msg void OnNMClickListRef(NMHDR *pNMHDR, LRESULT *pResult);
86 afx_msg void OnEnChangeEditFilter();
87 afx_msg void OnTimer(UINT_PTR nIDEvent);