OSDN Git Service

PATCH: [ 1229024 ] Rename CPropFilter to CPropLineFilter
authorPerry Rapp <elsapo@users.sourceforge.net>
Mon, 11 Jul 2005 20:33:06 +0000 (20:33 +0000)
committerPerry Rapp <elsapo@users.sourceforge.net>
Mon, 11 Jul 2005 20:33:06 +0000 (20:33 +0000)
  Rename class
   Src: PropLineFilter.cpp PropLineFilter.h
 (And adding the new/renamed PropLineFilter.* files)

Src/MainFrm.cpp
Src/PropLineFilter.cpp [new file with mode: 0644]
Src/PropLineFilter.h [new file with mode: 0644]
Src/readme.txt

index d8fd3df..f79ebf2 100644 (file)
@@ -2573,7 +2573,7 @@ void CMainFrame::OnFileNew()
 void CMainFrame::OnToolsFilters()
 {
        CPropertySheet sht(IDS_FILTER_TITLE);
-       CPropFilter filter;
+       CPropLineFilter filter;
        FileFiltersDlg fileFiltersDlg;
        FILEFILTER_INFOLIST fileFilters;
        CString selectedFilter;
diff --git a/Src/PropLineFilter.cpp b/Src/PropLineFilter.cpp
new file mode 100644 (file)
index 0000000..5c4bce4
--- /dev/null
@@ -0,0 +1,77 @@
+/**
+ *  @file PropLineFilter.cpp
+ *
+ *  @brief Implementation of Line Filter dialog
+ */ 
+// RCS ID line follows -- this is updated by CVS
+// $Id$
+
+#include "stdafx.h"
+#include "merge.h"
+#include "PropLineFilter.h"
+
+#ifdef _DEBUG
+#define new DEBUG_NEW
+#undef THIS_FILE
+static char THIS_FILE[] = __FILE__;
+#endif
+
+/////////////////////////////////////////////////////////////////////////////
+// CPropLineFilter property page
+
+IMPLEMENT_DYNAMIC(CPropLineFilter, CPropertyPage)
+
+CPropLineFilter::CPropLineFilter()
+: CPropertyPage(CPropLineFilter::IDD)
+{
+       //{{AFX_DATA_INIT(CPropLineFilter)
+       m_bIgnoreRegExp = FALSE;
+       m_sPattern = _T("");
+       //}}AFX_DATA_INIT
+}
+
+CPropLineFilter::~CPropLineFilter()
+{
+}
+
+void CPropLineFilter::DoDataExchange(CDataExchange* pDX)
+{
+       CPropertyPage::DoDataExchange(pDX);
+       //{{AFX_DATA_MAP(CPropLineFilter)
+       DDX_Control(pDX, IDC_EDITPATTERN, m_cPattern);
+       DDX_Check(pDX, IDC_IGNOREREGEXP, m_bIgnoreRegExp);
+       DDX_Text(pDX, IDC_EDITPATTERN, m_sPattern);
+       //}}AFX_DATA_MAP
+}
+
+
+BEGIN_MESSAGE_MAP(CPropLineFilter, CPropertyPage)
+       //{{AFX_MSG_MAP(CPropLineFilter)
+       ON_BN_CLICKED(IDC_IGNOREREGEXP, OnIgnoreregexp)
+       //}}AFX_MSG_MAP
+END_MESSAGE_MAP()
+
+/////////////////////////////////////////////////////////////////////////////
+// CPropLineFilter message handlers
+
+BOOL CPropLineFilter::OnInitDialog() 
+{
+       CPropertyPage::OnInitDialog();
+
+       m_cPattern.EnableWindow(m_bIgnoreRegExp);
+       
+       return TRUE;  // return TRUE unless you set the focus to a control
+                     // EXCEPTION: OCX Property Pages should return FALSE
+}
+
+
+/// User clicked the ignore checkbox
+void CPropLineFilter::OnIgnoreregexp() 
+{
+       UpdateData();
+       // enable or disable the edit box according to
+       // the value of the check box
+       m_cPattern.EnableWindow(m_bIgnoreRegExp);
+       if (m_bIgnoreRegExp)
+               m_cPattern.SetFocus();
+}
diff --git a/Src/PropLineFilter.h b/Src/PropLineFilter.h
new file mode 100644 (file)
index 0000000..7df62f1
--- /dev/null
@@ -0,0 +1,58 @@
+// PropLineFilter.h : header file
+//
+
+#if !defined(AFX_PROPFILTER_H__73E79E13_34DD_4C86_A3EC_A1044B721CCA__INCLUDED_)
+#define AFX_PROPFILTER_H__73E79E13_34DD_4C86_A3EC_A1044B721CCA__INCLUDED_
+
+/** 
+ * @file  PropLineFilter.h
+ *
+ * @brief Declaration file for Line Filter dialog
+ *
+ */
+// RCS ID line follows -- this is updated by CVS
+// $Id$
+
+/// Class for Line filter propertypage
+class CPropLineFilter : public CPropertyPage
+{
+       DECLARE_DYNAMIC(CPropLineFilter)
+
+// Construction
+public:
+       CPropLineFilter();
+       ~CPropLineFilter();
+
+// Dialog Data
+       //{{AFX_DATA(CPropLineFilter)
+       enum { IDD = IDD_PROPPAGE_FILTER };
+       CEdit   m_cPattern;
+       BOOL    m_bIgnoreRegExp;
+       CString m_sPattern;
+       //}}AFX_DATA
+
+// Implementation
+
+// Overrides
+       // ClassWizard generate virtual function overrides
+       //{{AFX_VIRTUAL(CPropLineFilter)
+       protected:
+       virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
+       //}}AFX_VIRTUAL
+
+// Implementation
+protected:
+
+       // Generated message map functions
+       //{{AFX_MSG(CPropLineFilter)
+       virtual BOOL OnInitDialog();
+       afx_msg void OnIgnoreregexp();
+       //}}AFX_MSG
+       DECLARE_MESSAGE_MAP()
+
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_PROPFILTER_H__73E79E13_34DD_4C86_A3EC_A1044B721CCA__INCLUDED_)
index 416c9ec..b2356d5 100644 (file)
@@ -3,6 +3,9 @@
   Remove PropFilter.cpp PropFilter.h
   Add PropLineFilter.cpp PropLineFilter.h
   Src: Merge.dsp MainFrm.cpp
+ PATCH: [ 1229024 ] Rename CPropFilter to CPropLineFilter
+  Rename class
+   Src: PropLineFilter.cpp PropLineFilter.h
 
 2005-07-08 Tim
  PATCH: [ 1232760 ] Icon for 'Merge->Delete'