1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/msw/evtloopconsole.h
3 // Purpose: wxConsoleEventLoop class for Windows
4 // Author: Vadim Zeitlin
7 // Copyright: (c) 2003-2004 Vadim Zeitlin <vadim@wxwindows.org>
8 // Licence: wxWindows licence
9 ///////////////////////////////////////////////////////////////////////////////
11 #ifndef _WX_MSW_EVTLOOPCONSOLE_H_
12 #define _WX_MSW_EVTLOOPCONSOLE_H_
14 class WXDLLIMPEXP_BASE wxMSWEventLoopBase
: public wxEventLoopManual
19 // implement base class pure virtuals
20 virtual bool Pending() const;
23 // get the next message from queue and return true or return false if we
24 // got WM_QUIT or an error occurred
25 bool GetNextMessage(WXMSG
*msg
);
27 // same as above but with a timeout and return value can be -1 meaning that
28 // time out expired in addition to
29 int GetNextMessageTimeout(WXMSG
*msg
, unsigned long timeout
);
32 #if wxUSE_CONSOLE_EVENTLOOP
34 class WXDLLIMPEXP_BASE wxConsoleEventLoop
: public wxMSWEventLoopBase
37 wxConsoleEventLoop() { }
39 // override/implement base class virtuals
40 virtual bool Dispatch();
41 virtual int DispatchTimeout(unsigned long timeout
);
42 virtual void WakeUp();
43 virtual bool YieldFor(long WXUNUSED(eventsToProcess
)) { return true; }
45 // Windows-specific function to process a single message
46 virtual void ProcessMessage(WXMSG
*msg
);
49 #endif // wxUSE_CONSOLE_EVENTLOOP
51 #endif // _WX_MSW_EVTLOOPCONSOLE_H_