forked from qt-creator/qt-creator
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:
@@ -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.")
|
||||
|
@@ -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
|
||||
|
||||
|
@@ -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"
|
||||
|
@@ -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()) {
|
||||
|
@@ -56,6 +56,8 @@
|
||||
|
||||
#define GAP_TIME 150
|
||||
|
||||
using QmlJsDebugClient::QDeclarativeDebugClient;
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
|
||||
|
@@ -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 {
|
||||
|
||||
|
Reference in New Issue
Block a user