summaryrefslogtreecommitdiff
path: root/libopie2/opiecore/oprocctrl.h
Unidiff
Diffstat (limited to 'libopie2/opiecore/oprocctrl.h') (more/less context) (ignore whitespace changes)
-rw-r--r--libopie2/opiecore/oprocctrl.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/libopie2/opiecore/oprocctrl.h b/libopie2/opiecore/oprocctrl.h
index 44b8a48..4922ba2 100644
--- a/libopie2/opiecore/oprocctrl.h
+++ b/libopie2/opiecore/oprocctrl.h
@@ -13,51 +13,56 @@
13 13
14 You should have received a copy of the GNU Library General Public License 14 You should have received a copy of the GNU Library General Public License
15 along with this library; see the file COPYING.LIB. If not, write to 15 along with this library; see the file COPYING.LIB. If not, write to
16 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 16 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 Boston, MA 02111-1307, USA. 17 Boston, MA 02111-1307, USA.
18*/ 18*/
19// 19//
20// KPROCESSCONTROLLER -- A helper class for KProcess 20// KPROCESSCONTROLLER -- A helper class for KProcess
21// 21//
22// version 0.3.1, Jan 8th 1997 22// version 0.3.1, Jan 8th 1997
23// 23//
24// (C) Christian Czezatke 24// (C) Christian Czezatke
25// e9025461@student.tuwien.ac.at 25// e9025461@student.tuwien.ac.at
26// Ported by Holger Freyther 26// Ported by Holger Freyther
27// 27//
28 28
29#ifndef __KPROCCTRL_H__ 29#ifndef __KPROCCTRL_H__
30#define __KPROCCTRL_H__ 30#define __KPROCCTRL_H__
31 31
32#include <qvaluelist.h> 32#include <qvaluelist.h>
33#include <qtimer.h> 33#include <qtimer.h>
34 34
35#include "oprocess.h" 35#include "oprocess.h"
36 36
37class OProcessControllerPrivate;
38class QSocketNotifier; 37class QSocketNotifier;
39 38
39
40namespace Opie {
41namespace Core {
42namespace Private {
43class OProcessControllerPrivate;
44
40/** 45/**
41 * @short Used internally by @ref OProcess 46 * @short Used internally by @ref OProcess
42 * @internal 47 * @internal
43 * @author Christian Czezakte <e9025461@student.tuwien.ac.at> 48 * @author Christian Czezakte <e9025461@student.tuwien.ac.at>
44 * 49 *
45 * A class for internal use by OProcess only. -- Exactly one instance 50 * A class for internal use by OProcess only. -- Exactly one instance
46 * of this class is generated by the first instance of OProcess that is 51 * of this class is generated by the first instance of OProcess that is
47 * created (a pointer to it gets stored in @ref theOProcessController ). 52 * created (a pointer to it gets stored in @ref theOProcessController ).
48 * 53 *
49 * This class takes care of the actual (UN*X) signal handling. 54 * This class takes care of the actual (UN*X) signal handling.
50*/ 55*/
51class OProcessController : public QObject 56class OProcessController : public QObject
52{ 57{
53 Q_OBJECT 58 Q_OBJECT
54 59
55public: 60public:
56 OProcessController(); 61 OProcessController();
57 ~OProcessController(); 62 ~OProcessController();
58 //CC: WARNING! Destructor Not virtual (but you don't derive classes from this anyhow...) 63 //CC: WARNING! Destructor Not virtual (but you don't derive classes from this anyhow...)
59 64
60public: 65public:
61 66
62 /** 67 /**
63 * Only a single instance of this class is allowed at a time, 68 * Only a single instance of this class is allowed at a time,
@@ -94,28 +99,31 @@ public:
94 void removeOProcess( OProcess* ); 99 void removeOProcess( OProcess* );
95public slots: 100public slots:
96 /** 101 /**
97 * @internal 102 * @internal
98 */ 103 */
99 void slotDoHousekeeping(int socket); 104 void slotDoHousekeeping(int socket);
100 105
101private slots: 106private slots:
102 void delayedChildrenCleanup(); 107 void delayedChildrenCleanup();
103private: 108private:
104 int fd[2]; 109 int fd[2];
105 QSocketNotifier *notifier; 110 QSocketNotifier *notifier;
106 static struct sigaction oldChildHandlerData; 111 static struct sigaction oldChildHandlerData;
107 static bool handlerSet; 112 static bool handlerSet;
108 QValueList<OProcess*> processList; 113 QValueList<OProcess*> processList;
109 QTimer delayedChildrenCleanupTimer; 114 QTimer delayedChildrenCleanupTimer;
110 115
111 // Disallow assignment and copy-construction 116 // Disallow assignment and copy-construction
112 OProcessController( const OProcessController& ); 117 OProcessController( const OProcessController& );
113 OProcessController& operator= ( const OProcessController& ); 118 OProcessController& operator= ( const OProcessController& );
114 119
115 OProcessControllerPrivate *d; 120 OProcessControllerPrivate *d;
116}; 121};
117 122
123}
124}
125}
118 126
119 127
120#endif 128#endif
121 129