X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/7fa03f04345b620d1a14529b05961116b20a1297..da9e956384a0619a0ecaa0bd1e4ba26b133b60a9:/include/wx/listbase.h diff --git a/include/wx/listbase.h b/include/wx/listbase.h index ef640effcb..c7f06adc7f 100644 --- a/include/wx/listbase.h +++ b/include/wx/listbase.h @@ -12,9 +12,7 @@ #ifndef _WX_LISTBASE_H_BASE_ #define _WX_LISTBASE_H_BASE_ -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) -// #pragma interface "listctrlbase.h" -#endif +#include "wx/defs.h" #if wxUSE_LISTCTRL @@ -371,7 +369,7 @@ public: const wxString& GetLabel() const { return m_item.m_text; } const wxString& GetText() const { return m_item.m_text; } int GetImage() const { return m_item.m_image; } - long GetData() const { return m_item.m_data; } + long GetData() const { return wx_static_cast(long, m_item.m_data); } long GetMask() const { return m_item.m_mask; } const wxListItem& GetItem() const { return m_item; } @@ -383,15 +381,6 @@ public: bool IsEditCancelled() const { return m_editCancelled; } void SetEditCanceled(bool editCancelled) { m_editCancelled = editCancelled; } -#if WXWIN_COMPATIBILITY_2_2 - // these methods don't do anything at all - long GetOldIndex() const { return 0; } - long GetOldItem() const { return 0; } - - // this one is superseded by GetKeyCode() - int GetCode() const { return GetKeyCode(); } -#endif // WXWIN_COMPATIBILITY_2_2 - virtual wxEvent *Clone() const { return new wxListEvent(*this); } //protected: -- not for backwards compatibility @@ -444,7 +433,7 @@ END_DECLARE_EVENT_TYPES() typedef void (wxEvtHandler::*wxListEventFunction)(wxListEvent&); #define wxListEventHandler(func) \ - (wxObjectEventFunction)wxStaticCastEvent(wxListEventFunction, &func) + (wxObjectEventFunction)(wxEventFunction)wxStaticCastEvent(wxListEventFunction, &func) #define wx__DECLARE_LISTEVT(evt, id, fn) \ wx__DECLARE_EVT1(wxEVT_COMMAND_LIST_ ## evt, id, wxListEventHandler(fn))