8#include <private/qqmlengine_p.h>
9#include <private/qv4compileddata_p.h>
18#if __cplusplus >= 202002L
19# define Q_ATOMIC_FLAG_INIT {}
21# define Q_ATOMIC_FLAG_INIT ATOMIC_FLAG_INIT
26void QQmlDebuggingEnabler::enableDebugging(
bool printWarning)
28 if (printWarning && !
s_printedWarning.test_and_set(std::memory_order_relaxed))
29 fprintf(stderr,
"QML debugging is enabled. Only use this in a safe environment.\n");
33#if QT_DEPRECATED_SINCE(6, 4)
34QQmlDebuggingEnabler::QQmlDebuggingEnabler(
bool printWarning)
36 enableDebugging(printWarning);
48 return {QV4DebugService::s_key, QQmlEngineDebugService::s_key, QDebugMessageService::s_key};
56QStringList QQmlDebuggingEnabler::inspectorServices()
58 return {QQmlInspectorService::s_key};
69 return {QQmlProfilerService::s_key, QQmlEngineControlService::s_key, QDebugMessageService::s_key};
78QStringList QQmlDebuggingEnabler::nativeDebuggerServices()
80 return {QQmlNativeDebugService::s_key};
97 QQmlDebugConnector::setServices(
services);
120bool QQmlDebuggingEnabler::startTcpDebugServer(
int port, StartMode
mode,
const QString &hostName)
126 return startDebugConnector(
QLatin1String(
"QQmlDebugServer"), configuration);
139bool QQmlDebuggingEnabler::connectToLocalDebugger(
const QString &socketFileName, StartMode
mode)
144 return startDebugConnector(
QLatin1String(
"QQmlDebugServer"), configuration);
157bool QQmlDebuggingEnabler::startDebugConnector(
const QString &pluginName,
160 QQmlDebugConnector::setPluginKey(pluginName);
162 return connector ? connector->
open(configuration) :
false;
std::vector< ObjCStrongReference< CBMutableService > > services
bool open(const QVariantHash &configuration=QVariantHash())
static QQmlDebugConnector * instance()
static std::atomic< bool > qml_debugging_enabled
\qmltype QtObject \instantiates QObject \inqmlmodule QtQml
\macro QT_RESTRICTED_CAST_FROM_ASCII
Combined button and popup list for selecting options.
#define Q_STATIC_ASSERT(Condition)
#define Q_ATOMIC_FLAG_INIT
quintptr Q_QML_EXPORT qtDeclarativeHookData[]
static Q_CONSTINIT std::atomic_flag s_printedWarning
QLatin1StringView QLatin1String
#define QT_REQUIRE_CONFIG(feature)
#define QV4_DATA_STRUCTURE_VERSION