X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/989ab1e5a604d3a44635d3ec50b520afdfe58077..38a097f588121ffcab2fa57e4494a6d0783c3567:/include/wx/msw/treectrl.h diff --git a/include/wx/msw/treectrl.h b/include/wx/msw/treectrl.h index 0afc4f5c5d..5729f58904 100644 --- a/include/wx/msw/treectrl.h +++ b/include/wx/msw/treectrl.h @@ -224,6 +224,7 @@ public: virtual WXLRESULT MSWDefWindowProc(WXUINT nMsg, WXWPARAM wParam, WXLPARAM lParam); virtual bool MSWCommand(WXUINT param, WXWORD id); virtual bool MSWOnNotify(int idCtrl, WXLPARAM lParam, WXLPARAM *result); + virtual bool MSWShouldPreProcessMessage(WXMSG* msg); // override some base class virtuals virtual bool SetBackgroundColour(const wxColour &colour); @@ -247,11 +248,6 @@ protected: // end edit label void DoEndEditLabel(bool discardChanges = false); - - // data used only while editing the item label: - wxTextCtrl *m_textCtrl; // text control in which it is edited - wxTreeItemId m_idEdited; // the item being edited - virtual wxTreeItemId DoInsertItem(const wxTreeItemId& parent, size_t pos, const wxString& text, @@ -262,7 +258,15 @@ protected: const wxString& text, int image = -1, int selImage = -1, wxTreeItemData *data = NULL); - virtual wxTreeItemId DoTreeHitTest(const wxPoint& point, int& flags); + virtual wxTreeItemId DoTreeHitTest(const wxPoint& point, int& flags) const; + + // obtain the user data for the lParam member of TV_ITEM + class wxTreeItemParam *GetItemParam(const wxTreeItemId& item) const; + + + // data used only while editing the item label: + wxTextCtrl *m_textCtrl; // text control in which it is edited + wxTreeItemId m_idEdited; // the item being edited private: // the common part of all ctors @@ -274,23 +278,8 @@ private: inline void DoExpand(const wxTreeItemId& item, int flag); - int DoGetItemImageFromData(const wxTreeItemId& item, - wxTreeItemIcon which) const; - void DoSetItemImageFromData(const wxTreeItemId& item, - int image, - wxTreeItemIcon which) const; - void DoSetItemImages(const wxTreeItemId& item, int image, int imageSel); - void DeleteTextCtrl(); - // support for additional item images which we implement using - // wxTreeItemIndirectData technique - see the comments in msw/treectrl.cpp - void SetIndirectItemData(const wxTreeItemId& item, - class wxTreeItemIndirectData *data); - bool HasIndirectData(const wxTreeItemId& item) const; - bool IsDataIndirect(wxTreeItemData *data) const - { return data && data->GetId().m_pItem == 0; } - // the hash storing the items attributes (indexed by item ids) wxMapTreeAttr m_attrs;