FLImaging 7.4.14.3
GUIEditCtrl.h
1#pragma once
2
10
11#include "GUIEditBase.h"
12#include "GUIWndCtrlBase.h"
13
15namespace FLImaging
16{
18 namespace GUI
19 {
20 class CGUIDialogKernel;
21
29 class FL_EXPORT CGUIEditCtrl : public CGUIEditBase, public CGUIWndCtrlBase
30 {
31 public:
40
48 virtual ~CGUIEditCtrl();
49
65 virtual bool SetWndCtrlProcedureOnEndEdit(FLImaging::GUI::CWndCtrlProcedure* pFunc, bool bAutoDestroy = true);
66
78 virtual FLImaging::GUI::CWndCtrlProcedure* GetWndCtrlProcedureOnEndEdit() const;
79
89 virtual void ActivateWndCtrlProcedureOnEndEdit(bool bActivate);
90
101
102 public:
103 virtual const CResult SetValue(const Base::CFLString<wchar_t>& flstrValue) override;
104
105 protected:
106 void PreSubclassWindow();
107
108 virtual void OnEditPaste() override;
109 virtual void OnEditCut() override;
110
111 protected:
112 BOOL m_bEditing;
113 bool m_bSingleLine;
114
115 CWndCtrlProcedure* m_pProcedureOnEndEdit;
116 bool m_bProcedureOnEndEditAutoDestroy;
117 bool m_bWndCtrlProcedureOnEndEditActive;
118
119 friend class CGUIDialogKernel;
120 public:
121 DECLARE_MESSAGE_MAP()
122 afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
123 afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
124 afx_msg void OnMouseHover(UINT nFlags, CPoint point);
125 afx_msg void OnMouseLeave();
126 afx_msg void OnMouseMove(UINT nFlags, CPoint point);
127 afx_msg void OnSetFocus(CWnd* pOldWnd);
128 afx_msg void OnKillFocus(CWnd* pNewWnd);
129 afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);
130 afx_msg int OnMouseActivate(CWnd* pDesktopWnd, UINT nHitTest, UINT message);
131 afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
132 afx_msg void OnNcPaint();
133 afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);
134 afx_msg void OnEnKillfocus();
135 };
136 }
137}
Template type string class.
Definition FLString.h:34
FLImaging module execution result object.
Definition ResultsDef.h:1676
Definition GUIDialogKernel.h:51
CGUIEditBase()
Default constructor.
virtual void OnEditCut() override
Function that is invoked by a cut event.
virtual void OnEditPaste() override
Function that is invoked by a paste event.
virtual void ActivateWndCtrlProcedureOnEndEdit(bool bActivate)
Activates or deactivates the callback function for end-edit events.
CGUIEditCtrl()
Default constructor.
virtual FLImaging::GUI::CWndCtrlProcedure * GetWndCtrlProcedureOnEndEdit() const
Retrieves the callback function set for end-edit events.
virtual bool SetWndCtrlProcedureOnEndEdit(FLImaging::GUI::CWndCtrlProcedure *pFunc, bool bAutoDestroy=true)
Sets a callback function that will be triggered when editing ends.
virtual bool IsWndCtrlProcedureOnEndEditActivated() const
Checks whether the callback function for end-edit events is currently activated.
virtual const CResult SetValue(const Base::CFLString< wchar_t > &flstrValue) override
A function that sets the input value, the value is modified and stored for the input type you set.
virtual ~CGUIEditCtrl()
Default destructor.
Definition D2DObject.h:12