Qt 4.8
Classes | Functions | Variables
qeventdispatcher_glib_qpa.cpp File Reference
#include "qeventdispatcher_glib_qpa_p.h"
#include "qapplication.h"
#include "qplatformdefs.h"
#include <glib.h>
#include "qapplication_p.h"
#include <qdebug.h>

Go to the source code of this file.

Classes

struct  GUserEventSource
 

Functions

static gboolean userEventSourceCheck (GSource *source)
 
static gboolean userEventSourceDispatch (GSource *s, GSourceFunc, gpointer)
 
static gboolean userEventSourcePrepare (GSource *s, gint *timeout)
 

Variables

static GSourceFuncs userEventSourceFuncs
 

Function Documentation

◆ userEventSourceCheck()

static gboolean userEventSourceCheck ( GSource *  source)
static

Definition at line 70 of file qeventdispatcher_glib_qpa.cpp.

71 {
72  return userEventSourcePrepare(source, 0);
73 }
static gboolean userEventSourcePrepare(GSource *s, gint *timeout)

◆ userEventSourceDispatch()

static gboolean userEventSourceDispatch ( GSource *  s,
GSourceFunc  ,
gpointer   
)
static

Definition at line 75 of file qeventdispatcher_glib_qpa.cpp.

76 {
77  GUserEventSource * source = reinterpret_cast<GUserEventSource *>(s);
78 
82  if (!event)
83  break;
84 
85  // send through event filter
86  if (source->q->filterEvent(event)) {
87  delete event;
88  continue;
89  }
90  QApplicationPrivate::processWindowSystemEvent(event);
91  delete event;
92  }
93 
94  return true;
95 }
bool filterEvent(void *message)
Sends message through the event filter that was set by setEventFilter().
EventRef event
QPAEventDispatcherGlib * q
static WindowSystemEvent * getWindowSystemEvent()

◆ userEventSourcePrepare()

static gboolean userEventSourcePrepare ( GSource *  s,
gint *  timeout 
)
static

Definition at line 62 of file qeventdispatcher_glib_qpa.cpp.

Referenced by userEventSourceCheck().

63 {
64  Q_UNUSED(s)
65  Q_UNUSED(timeout)
66 
68 }
#define Q_UNUSED(x)
Indicates to the compiler that the parameter with the specified name is not used in the body of a fun...
Definition: qglobal.h:1729

Variable Documentation

◆ userEventSourceFuncs

GSourceFuncs userEventSourceFuncs
static
Initial value:
= {
NULL,
NULL,
NULL
}
static gboolean userEventSourcePrepare(GSource *s, gint *timeout)
static gboolean userEventSourceCheck(GSource *source)
static gboolean userEventSourceDispatch(GSource *s, GSourceFunc, gpointer)

Definition at line 98 of file qeventdispatcher_glib_qpa.cpp.

Referenced by QPAEventDispatcherGlibPrivate::QPAEventDispatcherGlibPrivate().