Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
qcoreapplication.cpp File Reference

(947fd416e4ee50295ecdd8a20ca63460ecf0b1f1)

#include "qcoreapplication.h"
#include "qcoreapplication_p.h"
#include "qabstracteventdispatcher.h"
#include "qcoreevent.h"
#include "qcoreevent_p.h"
#include "qeventloop.h"
#include "qmetaobject.h"
#include <private/qproperty_p.h>
#include <qdatastream.h>
#include <qdebug.h>
#include <qdir.h>
#include <qfile.h>
#include <qfileinfo.h>
#include <private/qfilesystementry_p.h>
#include <qmutex.h>
#include <private/qloggingregistry_p.h>
#include <qscopeguard.h>
#include <qstandardpaths.h>
#include <qthread.h>
#include <qthreadstorage.h>
#include <private/qthread_p.h>
#include <qlibraryinfo.h>
#include <qpointer.h>
#include <qvarlengtharray.h>
#include <private/qfactoryloader_p.h>
#include <private/qfunctions_p.h>
#include <private/qlocale_p.h>
#include <private/qlocking_p.h>
#include <private/qhooks_p.h>
#include <private/qnativeinterface_p.h>
#include <stdlib.h>
#include <qtcore_tracepoints_p.h>
#include <algorithm>
#include <memory>
#include <string>
#include "moc_qcoreapplication.cpp"
Include dependency graph for qcoreapplication.cpp:

Go to the source code of this file.

Classes

struct  QCoreApplicationData

Typedefs

typedef QList< QtStartUpFunctionQStartUpFuncList
typedef QList< QtCleanUpFunctionQVFuncList

Functions

 Q_TRACE_PREFIX (qtcore, "#include <qcoreevent.h>")
 Q_TRACE_METADATA (qtcore, "ENUM { AUTO, RANGE User ... MaxUser } QEvent::Type;")
 Q_TRACE_POINT (qtcore, QCoreApplication_postEvent_entry, QObject *receiver, QEvent *event, QEvent::Type type)
 Q_TRACE_POINT (qtcore, QCoreApplication_postEvent_exit)
 Q_TRACE_POINT (qtcore, QCoreApplication_postEvent_event_compressed, QObject *receiver, QEvent *event)
 Q_TRACE_POINT (qtcore, QCoreApplication_postEvent_event_posted, QObject *receiver, QEvent *event, QEvent::Type type)
 Q_TRACE_POINT (qtcore, QCoreApplication_sendEvent, QObject *receiver, QEvent *event, QEvent::Type type)
 Q_TRACE_POINT (qtcore, QCoreApplication_sendSpontaneousEvent, QObject *receiver, QEvent *event, QEvent::Type type)
 Q_TRACE_POINT (qtcore, QCoreApplication_notify_entry, QObject *receiver, QEvent *event, QEvent::Type type)
 Q_TRACE_POINT (qtcore, QCoreApplication_notify_exit, bool consumed, bool filtered)
void QT_MANGLE_NAMESPACE qt_startup_hook ()
void qAddPreRoutine (QtStartUpFunction p)
void qAddPostRoutine (QtCleanUpFunction p)
void qRemovePostRoutine (QtCleanUpFunction p)
static void qt_call_pre_routines ()
void Q_CORE_EXPORT qt_call_post_routines ()
qsizetype qGlobalPostedEventsCount ()
QString qAppName ()
void Q_TRACE_INSTRUMENT (qtcore) QCoreApplicationPrivate
static bool doNotify (QObject *, QEvent *)
static void replacePercentN (QString *result, int n)
QString qtTrId (const char *id, int n)
QString qTrId (const char *id, int n)
static QString qAppFileName ()

Variables

static Q_CONSTINIT QBasicMutex globalRoutinesMutex
static Q_CONSTINIT bool preRoutinesCalled = false
static Q_CONSTINIT bool quitLockEnabled = true

Typedef Documentation

◆ QStartUpFuncList

Definition at line 275 of file qcoreapplication.cpp.

◆ QVFuncList

Definition at line 277 of file qcoreapplication.cpp.

Function Documentation

◆ doNotify()

bool doNotify ( QObject * receiver,
QEvent * event )
static

Definition at line 1196 of file qcoreapplication.cpp.

◆ Q_TRACE_INSTRUMENT()

void Q_TRACE_INSTRUMENT ( qtcore )

Definition at line 776 of file qcoreapplication.cpp.

◆ Q_TRACE_METADATA()

Q_TRACE_METADATA ( qtcore ,
"ENUM { AUTO, RANGE User ... MaxUser } QEvent::Type;"  )

◆ Q_TRACE_POINT() [1/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_notify_entry ,
QObject * receiver,
QEvent * event,
QEvent::Type type )

◆ Q_TRACE_POINT() [2/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_notify_exit ,
bool consumed,
bool filtered )

◆ Q_TRACE_POINT() [3/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_postEvent_entry ,
QObject * receiver,
QEvent * event,
QEvent::Type type )

◆ Q_TRACE_POINT() [4/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_postEvent_event_compressed ,
QObject * receiver,
QEvent * event )

◆ Q_TRACE_POINT() [5/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_postEvent_event_posted ,
QObject * receiver,
QEvent * event,
QEvent::Type type )

◆ Q_TRACE_POINT() [6/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_postEvent_exit  )

◆ Q_TRACE_POINT() [7/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_sendEvent ,
QObject * receiver,
QEvent * event,
QEvent::Type type )

◆ Q_TRACE_POINT() [8/8]

Q_TRACE_POINT ( qtcore ,
QCoreApplication_sendSpontaneousEvent ,
QObject * receiver,
QEvent * event,
QEvent::Type type )

◆ Q_TRACE_PREFIX()

Q_TRACE_PREFIX ( qtcore ,
"#include <qcoreevent.h>"  )

◆ qAddPostRoutine()

void qAddPostRoutine ( QtCleanUpFunction p)
related

Definition at line 305 of file qcoreapplication.cpp.

◆ qAddPreRoutine()

void qAddPreRoutine ( QtStartUpFunction p)

Adds a global routine that will be called from the QCoreApplication constructor. The public API is Q_COREAPP_STARTUP_FUNCTION.

Definition at line 288 of file qcoreapplication.cpp.

References preRoutinesCalled.

◆ qAppFileName()

QString qAppFileName ( )
static

Definition at line 2413 of file qcoreapplication.cpp.

◆ qAppName()

QString qAppName ( )

Definition at line 549 of file qcoreapplication.cpp.

◆ qGlobalPostedEventsCount()

qsizetype qGlobalPostedEventsCount ( )

Definition at line 371 of file qcoreapplication.cpp.

◆ qRemovePostRoutine()

void qRemovePostRoutine ( QtCleanUpFunction p)
related

Definition at line 314 of file qcoreapplication.cpp.

◆ qt_call_post_routines()

Q_CORE_EXPORT void qt_call_post_routines ( )

Definition at line 343 of file qcoreapplication.cpp.

◆ qt_call_pre_routines()

void qt_call_pre_routines ( )
static

Definition at line 323 of file qcoreapplication.cpp.

References preRoutinesCalled.

◆ qt_startup_hook()

void QT_MANGLE_NAMESPACE qt_startup_hook ( )

Definition at line 271 of file qcoreapplication.cpp.

◆ qTrId()

QString qTrId ( const char * id,
int n )

Definition at line 2347 of file qcoreapplication.cpp.

◆ qtTrId()

QString qtTrId ( const char * id,
int n )

Definition at line 2342 of file qcoreapplication.cpp.

◆ replacePercentN()

void replacePercentN ( QString * result,
int n )
static

Definition at line 2250 of file qcoreapplication.cpp.

Variable Documentation

◆ globalRoutinesMutex

Q_CONSTINIT QBasicMutex globalRoutinesMutex
static

Definition at line 279 of file qcoreapplication.cpp.

◆ preRoutinesCalled

Q_CONSTINIT bool preRoutinesCalled = false
static

Definition at line 280 of file qcoreapplication.cpp.

Referenced by qAddPreRoutine(), and qt_call_pre_routines().

◆ quitLockEnabled

Q_CONSTINIT bool quitLockEnabled = true
static

Definition at line 414 of file qcoreapplication.cpp.