diff options
author | Kai Koehne <kai.koehne@nokia.com> | 2012-03-27 09:20:20 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-03-27 09:46:00 +0200 |
commit | ffdbf216dc80b3d781307bb6b4b7150281c874a3 (patch) | |
tree | ff95763d5ad0ed2d96b1dd928f59c4a6d6af9e07 /src/qml/debugger | |
parent | 19977e9686a482a8189d928d8a45b282cb4287ba (diff) |
Debugger: Allow enabling of qml debugger without startup warning
Add QT_DECLARATIVE_DEBUG_NO_WARNING define to support enabling
the qml debugger without printing the usual startup warning.
This should be used with care, but e.g. for qmlscene the warning
probably confuses more than it helps.
Change-Id: I33704857baebfc8bca60abbff09138e259390b49
Reviewed-by: Aurindam Jana <aurindam.jana@nokia.com>
Diffstat (limited to 'src/qml/debugger')
-rw-r--r-- | src/qml/debugger/qqmldebug.h | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/qml/debugger/qqmldebug.h b/src/qml/debugger/qqmldebug.h index 8036032150..318e0bd71f 100644 --- a/src/qml/debugger/qqmldebug.h +++ b/src/qml/debugger/qqmldebug.h @@ -51,12 +51,14 @@ QT_BEGIN_NAMESPACE struct Q_QML_EXPORT QQmlDebuggingEnabler { - QQmlDebuggingEnabler(); + QQmlDebuggingEnabler(bool printWarning = true); }; // Execute code in constructor before first QQmlEngine is instantiated -#if defined(QT_DECLARATIVE_DEBUG) -static QQmlDebuggingEnabler qmlEnableDebuggingHelper; +#if defined(QT_DECLARATIVE_DEBUG_NO_WARNING) +static QQmlDebuggingEnabler qmlEnableDebuggingHelper(false); +#elif defined(QT_DECLARATIVE_DEBUG) +static QQmlDebuggingEnabler qmlEnableDebuggingHelper(true); #endif QT_END_NAMESPACE |