diff options
author | Ulf Hermann <ulf.hermann@digia.com> | 2014-09-09 18:22:58 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@digia.com> | 2014-09-15 09:15:24 +0200 |
commit | 6d58de0bad462ab4599428bb18d64d0cb0c7828d (patch) | |
tree | 7c274b60e0d69640019df2a3f4ebf4a03d409540 /src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp | |
parent | 7290c43da14c1f416c8de0654d8f335a3b271989 (diff) |
QmlProfiler: Allow preselection of events to be recorded
This allows us to reduce the amount of data we need to handle
if the user isn't interested in certain categories.
Task-number: QTBUG-41118
Change-Id: Ieaac12fb1dec29d6035642f433bc1a1d49e545c2
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Diffstat (limited to 'src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp')
-rw-r--r-- | src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp b/src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp index a272a7ac701..188fbcff197 100644 --- a/src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp +++ b/src/plugins/qmlprofiler/qmlprofilerstatemanager.cpp @@ -64,6 +64,7 @@ public: QmlProfilerStateManager::QmlProfilerState m_currentState; bool m_clientRecording; bool m_serverRecording; + quint64 m_recordingFeatures; }; QmlProfilerStateManager::QmlProfilerStateManager(QObject *parent) : QObject(parent),d(new QmlProfilerStateManagerPrivate(this)) @@ -71,6 +72,7 @@ QmlProfilerStateManager::QmlProfilerStateManager(QObject *parent) : d->m_currentState = Idle; d->m_clientRecording = true; d->m_serverRecording = false; + d->m_recordingFeatures = 0; } QmlProfilerStateManager::~QmlProfilerStateManager() @@ -93,6 +95,11 @@ bool QmlProfilerStateManager::serverRecording() return d->m_serverRecording; } +quint64 QmlProfilerStateManager::recordingFeatures() const +{ + return d->m_recordingFeatures; +} + QString QmlProfilerStateManager::currentStateAsString() { return stringForState(d->m_currentState); @@ -173,5 +180,13 @@ void QmlProfilerStateManager::setServerRecording(bool recording) } } +void QmlProfilerStateManager::setRecordingFeatures(quint64 features) +{ + if (d->m_recordingFeatures != features) { + d->m_recordingFeatures = features; + emit recordingFeaturesChanged(features); + } +} + } } |