#include "qeventdispatcher_glib_p.h"
#include "qeventdispatcher_unix_p.h"
#include <private/qmutexpool_p.h>
#include <private/qthread_p.h>
#include "qcoreapplication.h"
#include "qsocketnotifier.h"
#include <QtCore/qhash.h>
#include <QtCore/qlist.h>
#include <QtCore/qpair.h>
#include <glib.h>
Go to the source code of this file.
|
static gboolean | idleTimerSourceCheck (GSource *source) |
|
static gboolean | idleTimerSourceDispatch (GSource *source, GSourceFunc, gpointer) |
|
static gboolean | idleTimerSourcePrepare (GSource *source, gint *timeout) |
|
static gboolean | postEventSourceCheck (GSource *source) |
|
static gboolean | postEventSourceDispatch (GSource *s, GSourceFunc, gpointer) |
|
static gboolean | postEventSourcePrepare (GSource *s, gint *timeout) |
|
static gboolean | socketNotifierSourceCheck (GSource *source) |
|
static gboolean | socketNotifierSourceDispatch (GSource *source, GSourceFunc, gpointer) |
|
static gboolean | socketNotifierSourcePrepare (GSource *, gint *timeout) |
|
static gboolean | timerSourceCheck (GSource *source) |
|
static gboolean | timerSourceCheckHelper (GTimerSource *src) |
|
static gboolean | timerSourceDispatch (GSource *source, GSourceFunc, gpointer) |
|
static gboolean | timerSourcePrepare (GSource *source, gint *timeout) |
|
static gboolean | timerSourcePrepareHelper (GTimerSource *src, gint *timeout) |
|
◆ idleTimerSourceCheck()
static gboolean idleTimerSourceCheck |
( |
GSource * |
source | ) |
|
|
static |
Definition at line 219 of file qeventdispatcher_glib.cpp.
static gboolean timerSourceCheckHelper(GTimerSource *src)
GTimerSource * timerSource
◆ idleTimerSourceDispatch()
static gboolean idleTimerSourceDispatch |
( |
GSource * |
source, |
|
|
GSourceFunc |
, |
|
|
gpointer |
|
|
) |
| |
|
static |
◆ idleTimerSourcePrepare()
static gboolean idleTimerSourcePrepare |
( |
GSource * |
source, |
|
|
gint * |
timeout |
|
) |
| |
|
static |
Definition at line 205 of file qeventdispatcher_glib.cpp.
GTimerSource * timerSource
static gboolean timerSourcePrepareHelper(GTimerSource *src, gint *timeout)
◆ postEventSourceCheck()
static gboolean postEventSourceCheck |
( |
GSource * |
source | ) |
|
|
static |
◆ postEventSourceDispatch()
static gboolean postEventSourceDispatch |
( |
GSource * |
s, |
|
|
GSourceFunc |
, |
|
|
gpointer |
|
|
) |
| |
|
static |
Definition at line 276 of file qeventdispatcher_glib.cpp.
QEventDispatcherGlibPrivate * d
static void sendPostedEvents()
void runTimersOnceWithNormalPriority()
◆ postEventSourcePrepare()
static gboolean postEventSourcePrepare |
( |
GSource * |
s, |
|
|
gint * |
timeout |
|
) |
| |
|
static |
◆ socketNotifierSourceCheck()
static gboolean socketNotifierSourceCheck |
( |
GSource * |
source | ) |
|
|
static |
Definition at line 78 of file qeventdispatcher_glib.cpp.
83 for (
int i = 0; !pending && i < src->
pollfds.
count(); ++i) {
86 if (p->
pollfd.revents & G_IO_NVAL) {
88 static const char *t[] = {
"Read",
"Write",
"Exception" };
89 qWarning(
"QSocketNotifier: Invalid socket %d and type '%s', disabling...",
int count(const T &t) const
Returns the number of occurrences of value in the list.
QSocketNotifier * socketNotifier
Type type() const
Returns the socket event type specified to the constructor.
const T & at(int i) const
Returns the item at index position i in the list.
Q_CORE_EXPORT void qWarning(const char *,...)
QList< GPollFDWithQSocketNotifier * > pollfds
void setEnabled(bool)
If enable is true, the notifier is enabled; otherwise the notifier is disabled.
◆ socketNotifierSourceDispatch()
static gboolean socketNotifierSourceDispatch |
( |
GSource * |
source, |
|
|
GSourceFunc |
, |
|
|
gpointer |
|
|
) |
| |
|
static |
Definition at line 101 of file qeventdispatcher_glib.cpp.
int count(const T &t) const
Returns the number of occurrences of value in the list.
QSocketNotifier * socketNotifier
const T & at(int i) const
Returns the item at index position i in the list.
static bool sendEvent(QObject *receiver, QEvent *event)
Sends event event directly to receiver receiver, using the notify() function.
QList< GPollFDWithQSocketNotifier * > pollfds
The QEvent class is the base class of all event classes.
◆ socketNotifierSourcePrepare()
static gboolean socketNotifierSourcePrepare |
( |
GSource * |
, |
|
|
gint * |
timeout |
|
) |
| |
|
static |
◆ timerSourceCheck()
static gboolean timerSourceCheck |
( |
GSource * |
source | ) |
|
|
static |
◆ timerSourceCheckHelper()
static gboolean timerSourceCheckHelper |
( |
GTimerSource * |
src | ) |
|
|
static |
Definition at line 144 of file qeventdispatcher_glib.cpp.
Referenced by idleTimerSourceCheck(), and timerSourceCheck().
QEventLoop::ProcessEventsFlags processEventsFlags
timeval updateCurrentTime()
bool isEmpty() const
Returns true if the list contains no items; otherwise returns false.
T & first()
Returns a reference to the first item in the list.
◆ timerSourceDispatch()
static gboolean timerSourceDispatch |
( |
GSource * |
source, |
|
|
GSourceFunc |
, |
|
|
gpointer |
|
|
) |
| |
|
static |
◆ timerSourcePrepare()
static gboolean timerSourcePrepare |
( |
GSource * |
source, |
|
|
gint * |
timeout |
|
) |
| |
|
static |
◆ timerSourcePrepareHelper()
static gboolean timerSourcePrepareHelper |
( |
GTimerSource * |
src, |
|
|
gint * |
timeout |
|
) |
| |
|
static |
◆ idleTimerSourceFuncs
GSourceFuncs idleTimerSourceFuncs |
|
static |
Initial value:= {
NULL,
NULL,
NULL
}
static gboolean idleTimerSourceDispatch(GSource *source, GSourceFunc, gpointer)
static gboolean idleTimerSourceCheck(GSource *source)
static gboolean idleTimerSourcePrepare(GSource *source, gint *timeout)
Definition at line 237 of file qeventdispatcher_glib.cpp.
◆ postEventSourceFuncs
GSourceFuncs postEventSourceFuncs |
|
static |
◆ socketNotifierSourceFuncs
GSourceFuncs socketNotifierSourceFuncs |
|
static |
◆ timerSourceFuncs
GSourceFuncs timerSourceFuncs |
|
static |
Initial value:= {
NULL,
NULL,
NULL
}
static gboolean timerSourceDispatch(GSource *source, GSourceFunc, gpointer)
static gboolean timerSourceCheck(GSource *source)
static gboolean timerSourcePrepare(GSource *source, gint *timeout)
Definition at line 190 of file qeventdispatcher_glib.cpp.