]> git.saurik.com Git - wxWidgets.git/blob - include/wx/unix/apptbase.h
don't use generic process callback for wxGTK/Motif/MGL which have their own versions...
[wxWidgets.git] / include / wx / unix / apptbase.h
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$
8 // Copyright: (c) 2003 Vadim Zeitlin <vadim@wxwidgets.org>
9 // Licence: wxWindows licence
10 ///////////////////////////////////////////////////////////////////////////////
11
12 #ifndef _WX_UNIX_APPTBASE_H_
13 #define _WX_UNIX_APPTBASE_H_
14
15 struct wxExecuteData;
16 class wxPipe;
17
18 // ----------------------------------------------------------------------------
19 // wxAppTraits: the Unix version adds extra hooks needed by Unix code
20 // ----------------------------------------------------------------------------
21
22 class WXDLLIMPEXP_BASE wxAppTraits : public wxAppTraitsBase
23 {
24 public:
25 // wxExecute() support methods
26 // ---------------------------
27
28 // called before starting the child process and creates the pipe used for
29 // detecting the process termination asynchronously in GUI, does nothing in
30 // wxBase
31 //
32 // if it returns false, we should return from wxExecute() with an error
33 virtual bool CreateEndProcessPipe(wxExecuteData& execData);
34
35 // test if the given descriptor is the end of the pipe create by the
36 // function above
37 virtual bool IsWriteFDOfEndProcessPipe(wxExecuteData& execData, int fd);
38
39 // ensure that the write end of the pipe is not closed by wxPipe dtor
40 virtual void DetachWriteFDOfEndProcessPipe(wxExecuteData& execData);
41
42 // wait for the process termination, return whatever wxExecute() must
43 // return
44 virtual int WaitForChild(wxExecuteData& execData) = 0;
45
46
47 // wxThread helpers
48 // ----------------
49
50 // TODO
51
52 #if wxUSE_SOCKETS
53 // returns the select()-based socket manager for console applications which
54 // is also used by some ports (wxX11, wxDFB) in the GUI build (hence it is
55 // here and not in wxConsoleAppTraits)
56 virtual GSocketManager *GetSocketManager();
57 #endif
58 };
59
60 #endif // _WX_UNIX_APPTBASE_H_
61