X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e00a5d3ca15eec8db3e231d79d82ff6965e3466b..c6151f2a94c8851e712755839106707a863c5449:/include/wx/msw/textctrl.h diff --git a/include/wx/msw/textctrl.h b/include/wx/msw/textctrl.h index 7c67cb23e3..bc47dbd9f8 100644 --- a/include/wx/msw/textctrl.h +++ b/include/wx/msw/textctrl.h @@ -128,6 +128,11 @@ public: virtual void SetSelection(long from, long to); virtual void SetEditable(bool editable); + // Caret handling (Windows only) + + bool ShowNativeCaret(bool show = true); + bool HideNativeCaret() { return ShowNativeCaret(false); } + // Implementation from now on // -------------------------- @@ -184,6 +189,10 @@ public: // EDIT control has one already) void OnRightClick(wxMouseEvent& event); + // be sure the caret remains invisible if the user + // called HideNativeCaret() before + void OnSetFocus(wxFocusEvent& event); + protected: // common part of all ctors void Init(); @@ -242,9 +251,11 @@ protected: private: DECLARE_EVENT_TABLE() - DECLARE_DYNAMIC_CLASS(wxTextCtrl) + DECLARE_DYNAMIC_CLASS_NO_COPY(wxTextCtrl) wxMenu* m_privateContextMenu; + + bool m_isNativeCaretShown; }; #endif