QmlProfiler: Remove use of Qt private headers

Use the copy of QDeclarativeDebugClient we ship with qtcreator.
However, since the internal one misses a waitForConnected any connection
will right now fail.
This commit is contained in:
Kai Koehne
2011-04-14 15:49:12 +02:00
parent c8aa3dc8d2
commit 20cb599b8c
6 changed files with 12 additions and 9 deletions

View File

@@ -40,7 +40,8 @@ SUBDIRS = plugin_coreplugin \
plugin_analyzerbase \
plugin_qmljstools \
plugin_macros \
debugger/dumper.pro
debugger/dumper.pro \
plugin_qmlprofiler
!win32 {
SUBDIRS += plugin_valgrindtoolbase \
@@ -64,7 +65,6 @@ contains(QT_CONFIG, declarative) {
minQtVersion(4, 7, 1) {
SUBDIRS += plugin_qmldesigner
SUBDIRS += plugin_qmlprofiler
} else {
warning()
warning("QmlDesigner plugin has been disabled.")

View File

@@ -7,6 +7,7 @@ include(../../qtcreatorplugin.pri)
include(../../plugins/coreplugin/coreplugin.pri)
include(../../plugins/analyzerbase/analyzerbase.pri)
include(../../plugins/qmlprojectmanager/qmlprojectmanager.pri)
include(../../libs/qmljsdebugclient/qmljsdebugclient-lib.pri)
QT += network script declarative

View File

@@ -39,7 +39,7 @@
#include <analyzerbase/analyzermanager.h>
#include <analyzerbase/analyzerconstants.h>
#include <private/qdeclarativedebugclient_p.h>
#include <qmljsdebugclient/qdeclarativedebugclient_p.h>
#include "timelineview.h"
#include "tracewindow.h"

View File

@@ -38,7 +38,7 @@
#include "qmlprofilerattachdialog.h"
#include "tracewindow.h"
#include <private/qdeclarativedebugclient_p.h>
#include <qmljsdebugclient/qdeclarativedebugclient_p.h>
#include <analyzerbase/analyzermanager.h>
#include <analyzerbase/analyzerconstants.h>
@@ -146,7 +146,7 @@ QmlProfilerTool::QmlProfilerTool(QObject *parent)
QmlProfilerTool::~QmlProfilerTool()
{
if (d->m_client->isConnected())
d->m_client->disconnectFromHost();
d->m_client->close();
delete d->m_tabbed;
delete d->m_outputPaneAdapter;
@@ -304,7 +304,6 @@ void QmlProfilerTool::connectToClient()
d->m_client = newClient;
d->m_client->connectToHost(d->m_host, d->m_port);
d->m_client->waitForConnected();
if (d->m_client->isConnected()) {
d->m_traceWindow->setRecording(d->m_recordingEnabled);
@@ -323,10 +322,9 @@ void QmlProfilerTool::connectToClient()
void QmlProfilerTool::disconnectClient()
{
d->m_client->disconnectFromHost();
d->m_client->close();
}
void QmlProfilerTool::startRecording()
{
if (d->m_client->isConnected()) {

View File

@@ -56,6 +56,8 @@
#define GAP_TIME 150
using QmlJsDebugClient::QDeclarativeDebugClient;
namespace QmlProfiler {
namespace Internal {

View File

@@ -37,7 +37,7 @@
#include <QtCore/qpointer.h>
#include <QtGui/qwidget.h>
#include <QtDeclarative/private/qdeclarativedebugclient_p.h>
#include <qmljsdebugclient/qdeclarativedebugclient_p.h>
QT_BEGIN_NAMESPACE
@@ -50,6 +50,8 @@ class QPushButton;
class QDeclarativeView;
QT_END_NAMESPACE
using QmlJsDebugClient::QDeclarativeDebugConnection;
namespace QmlProfiler {
namespace Internal {