]> git.saurik.com Git - wxWidgets.git/blame - include/wx/unix/apptbase.h
Document wxKill(wxSIGTERM) reliance on having an open window in wxMSW.
[wxWidgets.git] / include / wx / unix / apptbase.h
CommitLineData
e2478fde
VZ
1///////////////////////////////////////////////////////////////////////////////
2// Name: wx/unix/apptbase.h
3// Purpose: declaration of wxAppTraits for Unix systems
4// Author: Vadim Zeitlin
5// Modified by:
6// Created: 23.06.2003
7// RCS-ID: $Id$
77ffb593 8// Copyright: (c) 2003 Vadim Zeitlin <vadim@wxwidgets.org>
65571936 9// Licence: wxWindows licence
e2478fde
VZ
10///////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_UNIX_APPTBASE_H_
13#define _WX_UNIX_APPTBASE_H_
14
821d856a
VZ
15#include "wx/evtloop.h"
16#include "wx/evtloopsrc.h"
17
18class wxExecuteData;
6bcc1145 19class wxFDIOManager;
71e9885b 20class wxEventLoopSourcesManagerBase;
e2478fde
VZ
21
22// ----------------------------------------------------------------------------
23// wxAppTraits: the Unix version adds extra hooks needed by Unix code
24// ----------------------------------------------------------------------------
25
163b3ad7 26class WXDLLIMPEXP_BASE wxAppTraits : public wxAppTraitsBase
e2478fde
VZ
27{
28public:
29 // wxExecute() support methods
30 // ---------------------------
31
821d856a 32 // Wait for the process termination and return its exit code or -1 on error.
1d043598 33 //
821d856a
VZ
34 // Notice that this is only used when execData.flags contains wxEXEC_SYNC
35 // and does not contain wxEXEC_NOEVENTS, i.e. when we need to really wait
36 // until the child process exit and dispatch the events while doing it.
1d043598
VZ
37 virtual int WaitForChild(wxExecuteData& execData);
38
6bcc1145
VZ
39#if wxUSE_SOCKETS
40 // return a pointer to the object which should be used to integrate
41 // monitoring of the file descriptors to the event loop (currently this is
42 // used for the sockets only but should be used for arbitrary event loop
43 // sources in the future)
44 //
45 // this object may be different for the console and GUI applications
46 //
47 // the pointer is not deleted by the caller as normally it points to a
48 // static variable
49 virtual wxFDIOManager *GetFDIOManager();
50#endif // wxUSE_SOCKETS
e2478fde 51
ccf8bf20 52#if wxUSE_CONSOLE_EVENTLOOP
71e9885b
VZ
53 // Return a non-NULL pointer to the object responsible for managing the
54 // event loop sources in this kind of application.
55 virtual wxEventLoopSourcesManagerBase* GetEventLoopSourcesManager();
ccf8bf20 56#endif // wxUSE_CONSOLE_EVENTLOOP
71e9885b 57
9d3845e8 58protected:
821d856a
VZ
59 // Wait for the process termination by running the given event loop until
60 // this happens.
61 //
62 // This is used by the public WaitForChild() after creating the event loop
63 // of the appropriate kind.
64 int RunLoopUntilChildExit(wxExecuteData& execData, wxEventLoopBase& loop);
e2478fde
VZ
65};
66
67#endif // _WX_UNIX_APPTBASE_H_
68