X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/924b84ab9461c95cf5c5386d1091ae0f7a8e7ce7..847379b00c3349dc693535b65296b92cc4646897:/include/wx/event.h diff --git a/include/wx/event.h b/include/wx/event.h index c8dda1ec36..4563a36f16 100644 --- a/include/wx/event.h +++ b/include/wx/event.h @@ -514,7 +514,9 @@ private: #ifdef __VISUALC__ // 'this' : used in base member initializer list (for m_commandString) - #pragma warning(push) + #if _MSC_VER > 1100 + #pragma warning(push) + #endif #pragma warning(disable:4355) #endif @@ -580,7 +582,7 @@ private: DECLARE_DYNAMIC_CLASS_NO_ASSIGN(wxCommandEvent) }; -#ifdef __VISUALC__ +#if defined(__VISUALC__) && (_MSC_VER > 1100) #pragma warning(pop) #endif @@ -2295,8 +2297,6 @@ protected: // wxEvtHandler: the base class for all objects handling wxWidgets events // ---------------------------------------------------------------------------- -typedef void (wxEvtHandler::*wxEventFunction)(wxEvent&); - class WXDLLIMPEXP_BASE wxEvtHandler : public wxObject { public: @@ -2324,15 +2324,6 @@ public: bool ProcessThreadEvent(wxEvent& event); #endif -#if wxUSE_EXCEPTIONS - // call the specified handler with the given event - // - // this method only exists to allow catching the exceptions thrown by any - // event handler, it would lead to an extra (useless) virtual function call - // if the exceptions were not used, so it doesn't even exist in that case - virtual void DoHandleEvent(wxEventFunction func, wxEvent& event); -#endif // wxUSE_EXCEPTIONS - // Dynamic association of a member function handler with the event handler, // winid and event type void Connect(int winid, @@ -2493,6 +2484,8 @@ inline void wxPostEvent(wxEvtHandler *dest, wxEvent& event) dest->AddPendingEvent(event); } +typedef void (wxEvtHandler::*wxEventFunction)(wxEvent&); + #define wxEventHandler(func) \ (wxObjectEventFunction)wxStaticCastEvent(wxEventFunction, &func)