aboutsummaryrefslogtreecommitdiffstats
path: root/src/declarative/debugger
diff options
context:
space:
mode:
authorAurindam Jana <aurindam.jana@nokia.com>2011-11-10 16:12:45 +0100
committerQt by Nokia <qt-info@nokia.com>2011-11-11 14:56:27 +0100
commit40360f040d9aa110997b375a460de5e6e4203ad6 (patch)
tree68a917f469756c87c695a5ebc19c198779835f17 /src/declarative/debugger
parentf15b7a0ffb15bf34749bed750f98a23c84a89f7f (diff)
QV8ProfileService: Code refactor
Define sendProfilingData() to send data to client. Change-Id: I1f4778946af4552ef6323c78a538ab7149990b0a Reviewed-by: Christiaan Janssen <christiaan.janssen@nokia.com>
Diffstat (limited to 'src/declarative/debugger')
-rw-r--r--src/declarative/debugger/qv8profilerservice.cpp10
-rw-r--r--src/declarative/debugger/qv8profilerservice_p.h2
2 files changed, 10 insertions, 2 deletions
diff --git a/src/declarative/debugger/qv8profilerservice.cpp b/src/declarative/debugger/qv8profilerservice.cpp
index c611366974..48d2d1365d 100644
--- a/src/declarative/debugger/qv8profilerservice.cpp
+++ b/src/declarative/debugger/qv8profilerservice.cpp
@@ -152,8 +152,7 @@ void QV8ProfilerService::messageReceived(const QByteArray &message)
startProfiling(QString::fromUtf8(title));
} else if (option == "stop") {
stopProfiling(QString::fromUtf8(title));
- // Send messages to client
- d->sendMessages();
+ sendProfilingData();
}
d->initialized = true;
}
@@ -191,6 +190,13 @@ void QV8ProfilerService::stopProfiling(const QString &title)
}
}
+void QV8ProfilerService::sendProfilingData()
+{
+ Q_D(QV8ProfilerService);
+ // Send messages to client
+ d->sendMessages();
+}
+
void QV8ProfilerServicePrivate::printProfileTree(const v8::CpuProfileNode *node, int level)
{
for (int index = 0 ; index < node->GetChildrenCount() ; index++) {
diff --git a/src/declarative/debugger/qv8profilerservice_p.h b/src/declarative/debugger/qv8profilerservice_p.h
index ea5119cd50..f2d517b6df 100644
--- a/src/declarative/debugger/qv8profilerservice_p.h
+++ b/src/declarative/debugger/qv8profilerservice_p.h
@@ -100,6 +100,8 @@ public:
void startProfiling(const QString &title);
void stopProfiling(const QString &title);
+ void sendProfilingData();
+
protected:
void messageReceived(const QByteArray &);