forked from qt-creator/qt-creator
QmlJSDebugClient: Move QmlProfilerTraceClient into library
Change-Id: I1c0821778a3350ec55741b45680fca2cb1fed3aa Reviewed-on: http://codereview.qt.nokia.com/2680 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: Christiaan Janssen <christiaan.janssen@nokia.com>
This commit is contained in:
@@ -10,12 +10,15 @@ HEADERS += \
|
||||
$$PWD/qdeclarativeenginedebug.h \
|
||||
$$PWD/qpacketprotocol.h \
|
||||
$$PWD/qdeclarativedebugclient.h \
|
||||
$$PWD/qmljsdebugclient_global.h
|
||||
$$PWD/qmljsdebugclient_global.h \
|
||||
$$PWD/qmlprofilertraceclient.h \
|
||||
$$PWD/qmlprofilereventtypes.h
|
||||
|
||||
SOURCES += \
|
||||
$$PWD/qdeclarativeenginedebug.cpp \
|
||||
$$PWD/qpacketprotocol.cpp \
|
||||
$$PWD/qdeclarativedebugclient.cpp
|
||||
$$PWD/qdeclarativedebugclient.cpp \
|
||||
$$PWD/qmlprofilertraceclient.cpp
|
||||
|
||||
OTHER_FILES += \
|
||||
$$PWD/qmljsdebugclient.pri \
|
||||
|
||||
@@ -33,8 +33,7 @@
|
||||
#ifndef QMLPROFILEREVENTTYPES_H
|
||||
#define QMLPROFILEREVENTTYPES_H
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
namespace QmlJsDebugClient {
|
||||
|
||||
enum QmlEventType {
|
||||
Painting,
|
||||
@@ -46,7 +45,6 @@ enum QmlEventType {
|
||||
MaximumQmlEventType
|
||||
};
|
||||
|
||||
}
|
||||
}
|
||||
} // namespace QmlJsDebugClient
|
||||
|
||||
#endif //QMLPROFILEREVENTTYPES_H
|
||||
@@ -32,7 +32,6 @@
|
||||
|
||||
#include "qmlprofilertraceclient.h"
|
||||
|
||||
using namespace QmlProfiler::Internal;
|
||||
using namespace QmlJsDebugClient;
|
||||
|
||||
static const int GAP_TIME = 150;
|
||||
@@ -33,16 +33,16 @@
|
||||
#ifndef QMLPROFILERTRACECLIENT_H
|
||||
#define QMLPROFILERTRACECLIENT_H
|
||||
|
||||
#include <qmljsdebugclient/qdeclarativedebugclient.h>
|
||||
#include "qdeclarativedebugclient.h"
|
||||
#include "qmlprofilereventtypes.h"
|
||||
#include "qmljsdebugclient_global.h"
|
||||
|
||||
#include <QtCore/QStack>
|
||||
#include <QtCore/QStringList>
|
||||
|
||||
#include "qmlprofilereventtypes.h"
|
||||
namespace QmlJsDebugClient {
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
|
||||
struct Location
|
||||
struct QMLJSDEBUGCLIENT_EXPORT Location
|
||||
{
|
||||
Location() : line(-1) {}
|
||||
Location(const QString &file, int lineNumber) : fileName(file), line(lineNumber) {}
|
||||
@@ -50,7 +50,7 @@ struct Location
|
||||
int line;
|
||||
};
|
||||
|
||||
class QmlProfilerTraceClient : public QmlJsDebugClient::QDeclarativeDebugClient
|
||||
class QMLJSDEBUGCLIENT_EXPORT QmlProfilerTraceClient : public QmlJsDebugClient::QDeclarativeDebugClient
|
||||
{
|
||||
Q_OBJECT
|
||||
Q_PROPERTY(bool recording READ isRecording WRITE setRecording NOTIFY recordingChanged)
|
||||
@@ -116,7 +116,6 @@ private:
|
||||
int m_nestingInType[MaximumQmlEventType];
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
} // namespace QmlProfiler
|
||||
} // namespace QmlJsDebugClient
|
||||
|
||||
#endif // QMLPROFILERTRACECLIENT_H
|
||||
@@ -26,7 +26,6 @@ SOURCES += \
|
||||
localqmlprofilerrunner.cpp \
|
||||
codaqmlprofilerrunner.cpp \
|
||||
remotelinuxqmlprofilerrunner.cpp \
|
||||
qmlprofilertraceclient.cpp \
|
||||
qmlprofilereventview.cpp \
|
||||
qmlprofilerruncontrolfactory.cpp
|
||||
|
||||
@@ -43,9 +42,7 @@ HEADERS += \
|
||||
localqmlprofilerrunner.h \
|
||||
codaqmlprofilerrunner.h \
|
||||
remotelinuxqmlprofilerrunner.h \
|
||||
qmlprofilertraceclient.h \
|
||||
qmlprofilereventview.h \
|
||||
qmlprofilereventtypes.h \
|
||||
qmlprofilerruncontrolfactory.h
|
||||
|
||||
RESOURCES += \
|
||||
|
||||
@@ -38,6 +38,8 @@
|
||||
#include <QtGui/QHeaderView>
|
||||
#include <QtGui/QStandardItemModel>
|
||||
|
||||
using namespace QmlJsDebugClient;
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
|
||||
|
||||
@@ -34,7 +34,7 @@
|
||||
#define QMLPROFILEREVENTVIEW_H
|
||||
|
||||
#include <QTreeView>
|
||||
#include "qmlprofilereventtypes.h"
|
||||
#include <qmljsdebugclient/qmlprofilereventtypes.h>
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
@@ -42,7 +42,7 @@ namespace Internal {
|
||||
struct QmlEventData
|
||||
{
|
||||
QmlEventData() : displayname(0) , filename(0) , location(0) , details(0),
|
||||
line(0), eventType(MaximumQmlEventType), level(-1), parentList(0), childrenList(0) {}
|
||||
line(0), eventType(QmlJsDebugClient::MaximumQmlEventType), level(-1), parentList(0), childrenList(0) {}
|
||||
~QmlEventData() {
|
||||
delete displayname;
|
||||
delete filename;
|
||||
@@ -55,7 +55,7 @@ struct QmlEventData
|
||||
QString *location;
|
||||
QString *details;
|
||||
int line;
|
||||
QmlEventType eventType;
|
||||
QmlJsDebugClient::QmlEventType eventType;
|
||||
qint64 level;
|
||||
QList< QmlEventData *> *parentList;
|
||||
QList< QmlEventData *> *childrenList;
|
||||
|
||||
@@ -33,9 +33,9 @@
|
||||
#include "tracewindow.h"
|
||||
|
||||
#include "qmlprofilerplugin.h"
|
||||
#include "qmlprofilertraceclient.h"
|
||||
|
||||
#include <qmljsdebugclient/qdeclarativedebugclient.h>
|
||||
#include <qmljsdebugclient/qmlprofilertraceclient.h>
|
||||
#include <utils/styledbar.h>
|
||||
|
||||
#include <QtDeclarative/QDeclarativeView>
|
||||
@@ -44,6 +44,8 @@
|
||||
#include <QtGui/QToolButton>
|
||||
#include <QtGui/QGraphicsObject>
|
||||
|
||||
using namespace QmlJsDebugClient;
|
||||
|
||||
namespace QmlProfiler {
|
||||
namespace Internal {
|
||||
|
||||
@@ -112,7 +114,7 @@ TraceWindow::~TraceWindow()
|
||||
delete m_plugin.data();
|
||||
}
|
||||
|
||||
void TraceWindow::reset(QmlJsDebugClient::QDeclarativeDebugConnection *conn)
|
||||
void TraceWindow::reset(QDeclarativeDebugConnection *conn)
|
||||
{
|
||||
if (m_plugin)
|
||||
disconnect(m_plugin.data(), SIGNAL(complete()), this, SIGNAL(viewUpdated()));
|
||||
|
||||
@@ -33,7 +33,7 @@
|
||||
#ifndef TRACEWINDOW_H
|
||||
#define TRACEWINDOW_H
|
||||
|
||||
#include "qmlprofilertraceclient.h"
|
||||
#include <qmljsdebugclient/qmlprofilertraceclient.h>
|
||||
|
||||
#include <QtCore/QPointer>
|
||||
#include <QtGui/QWidget>
|
||||
@@ -79,7 +79,7 @@ signals:
|
||||
void enableToolbar(bool);
|
||||
|
||||
private:
|
||||
QWeakPointer<QmlProfilerTraceClient> m_plugin;
|
||||
QWeakPointer<QmlJsDebugClient::QmlProfilerTraceClient> m_plugin;
|
||||
QSize m_sizeHint;
|
||||
|
||||
QDeclarativeView *m_view;
|
||||
|
||||
Reference in New Issue
Block a user