-#if wxUSE_GUI
- #include "wx/tooltip.h"
- #if wxUSE_THREADS
- #include "wx/thread.h"
-
- // define the list of MSG strutures
- WX_DECLARE_LIST(MSG, wxMsgList);
-
- #include "wx/listimpl.cpp"
-
- WX_DEFINE_LIST(wxMsgList)
- #endif // wxUSE_THREADS
-#endif //wxUSE_GUI
-
-#if wxUSE_BASE
-
-// ============================================================================
-// wxMSWEventLoopBase implementation
-// ============================================================================
-
-// ----------------------------------------------------------------------------
-// ctor/dtor
-// ----------------------------------------------------------------------------
-
-wxMSWEventLoopBase::wxMSWEventLoopBase()
-{
- m_shouldExit = false;
- m_exitcode = 0;
-}
-
-// ----------------------------------------------------------------------------
-// wxEventLoop message processing dispatching
-// ----------------------------------------------------------------------------
-
-bool wxMSWEventLoopBase::Pending() const
-{
- MSG msg;
- return ::PeekMessage(&msg, 0, 0, 0, PM_NOREMOVE) != 0;
-}
-
-bool wxMSWEventLoopBase::GetNextMessage(WXMSG* msg)
-{
- wxCHECK_MSG( IsRunning(), false, _T("can't get messages if not running") );
-
- const BOOL rc = ::GetMessage(msg, NULL, 0, 0);
-
- if ( rc == 0 )
- {
- // got WM_QUIT
- return false;
- }
-
- if ( rc == -1 )
- {
- // should never happen, but let's test for it nevertheless
- wxLogLastError(wxT("GetMessage"));
-
- // still break from the loop
- return false;
- }
-
- return true;
-}