summaryrefslogtreecommitdiff
path: root/qmake/include/private/qeventloop_p.h
Side-by-side diff
Diffstat (limited to 'qmake/include/private/qeventloop_p.h') (more/less context) (ignore whitespace changes)
-rw-r--r--qmake/include/private/qeventloop_p.h74
1 files changed, 74 insertions, 0 deletions
diff --git a/qmake/include/private/qeventloop_p.h b/qmake/include/private/qeventloop_p.h
new file mode 100644
index 0000000..b64d0df
--- a/dev/null
+++ b/qmake/include/private/qeventloop_p.h
@@ -0,0 +1,74 @@
+#ifndef QEVENTLOOP_P_H
+#define QEVENTLOOP_P_H
+
+#include "qplatformdefs.h"
+#include "qwindowdefs.h"
+
+class QSocketNotifier;
+
+#if defined(Q_OS_UNIX)
+#include <qptrlist.h>
+
+struct QSockNot
+{
+ QSocketNotifier *obj;
+ int fd;
+ fd_set *queue;
+};
+
+class QSockNotType
+{
+public:
+ QSockNotType();
+ ~QSockNotType();
+
+ QPtrList<QSockNot> *list;
+ fd_set select_fds;
+ fd_set enabled_fds;
+ fd_set pending_fds;
+
+};
+#endif // Q_OS_UNIX
+
+
+class QEventLoopPrivate
+{
+public:
+ QEventLoopPrivate()
+ {
+ reset();
+ }
+
+ void reset() {
+ looplevel = 0;
+ quitcode = 0;
+ quitnow = FALSE;
+ exitloop = FALSE;
+ }
+
+ int looplevel;
+ int quitcode;
+ bool quitnow;
+ bool exitloop;
+
+#if defined(Q_WS_MAC)
+ EventLoopTimerRef select_timer;
+#endif
+
+#if defined(Q_WS_X11)
+ int xfd;
+#endif // Q_WS_X11
+
+#if defined(Q_OS_UNIX)
+ int thread_pipe[2];
+
+ // pending socket notifiers list
+ QPtrList<QSockNot> sn_pending_list;
+ // highest fd for all socket notifiers
+ int sn_highest;
+ // 3 socket notifier types - read, write and exception
+ QSockNotType sn_vec[3];
+#endif
+};
+
+#endif // QEVENTLOOP_P_H