X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f55fee08e9d56f3994e0af75efe179d14a6258e7..5e06d749ed2e8fe82bf058e66695cd4a96e450da:/src/msw/dialog.cpp diff --git a/src/msw/dialog.cpp b/src/msw/dialog.cpp index d5a9b74930..ecac0fae54 100644 --- a/src/msw/dialog.cpp +++ b/src/msw/dialog.cpp @@ -17,10 +17,6 @@ // headers // ---------------------------------------------------------------------------- -#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) - #pragma implementation "dialog.h" -#endif - // For compilers that support precompilation, includes "wx.h". #include "wx/wxprec.h" @@ -33,6 +29,7 @@ #include "wx/utils.h" #include "wx/frame.h" #include "wx/app.h" + #include "wx/button.h" #include "wx/settings.h" #include "wx/intl.h" #include "wx/log.h" @@ -146,7 +143,7 @@ private: wxModalEventLoop m_evtLoop; }; -wxDEFINE_TIED_SCOPED_PTR_TYPE(wxDialogModalData); +wxDEFINE_TIED_SCOPED_PTR_TYPE(wxDialogModalData) // ============================================================================ // implementation @@ -387,7 +384,7 @@ bool wxDialog::EmulateButtonClickIfPresent(int id) { wxButton *btn = wxDynamicCast(FindWindow(id), wxButton); - if ( !btn || !btn->IsEnabled() ) + if ( !btn || !btn->IsEnabled() || !btn->IsShown() ) return false; btn->MSWCommand(BN_CLICKED, 0 /* unused */);