forked from qt-creator/qt-creator
QmlProfiler: renamed runcontrol factory
Change-Id: I1d857d5cf63c01d766874469e7edde6a2c591dca Reviewed-on: http://codereview.qt.nokia.com/1162 Reviewed-by: Qt Sanity Bot <qt_sanity_bot@ovi.com> Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
@@ -23,12 +23,12 @@ SOURCES += \
|
|||||||
tracewindow.cpp \
|
tracewindow.cpp \
|
||||||
timelineview.cpp \
|
timelineview.cpp \
|
||||||
qmlprofilerattachdialog.cpp \
|
qmlprofilerattachdialog.cpp \
|
||||||
qmlprojectanalyzerruncontrolfactory.cpp \
|
|
||||||
localqmlprofilerrunner.cpp \
|
localqmlprofilerrunner.cpp \
|
||||||
codaqmlprofilerrunner.cpp \
|
codaqmlprofilerrunner.cpp \
|
||||||
remotelinuxqmlprofilerrunner.cpp \
|
remotelinuxqmlprofilerrunner.cpp \
|
||||||
qmlprofilertraceclient.cpp \
|
qmlprofilertraceclient.cpp \
|
||||||
qmlprofilereventview.cpp
|
qmlprofilereventview.cpp \
|
||||||
|
qmlprofilerruncontrolfactory.cpp
|
||||||
|
|
||||||
HEADERS += \
|
HEADERS += \
|
||||||
qmlprofilerconstants.h \
|
qmlprofilerconstants.h \
|
||||||
@@ -39,14 +39,14 @@ HEADERS += \
|
|||||||
tracewindow.h \
|
tracewindow.h \
|
||||||
timelineview.h \
|
timelineview.h \
|
||||||
qmlprofilerattachdialog.h \
|
qmlprofilerattachdialog.h \
|
||||||
qmlprojectanalyzerruncontrolfactory.h \
|
|
||||||
abstractqmlprofilerrunner.h \
|
abstractqmlprofilerrunner.h \
|
||||||
localqmlprofilerrunner.h \
|
localqmlprofilerrunner.h \
|
||||||
codaqmlprofilerrunner.h \
|
codaqmlprofilerrunner.h \
|
||||||
remotelinuxqmlprofilerrunner.h \
|
remotelinuxqmlprofilerrunner.h \
|
||||||
qmlprofilertraceclient.h \
|
qmlprofilertraceclient.h \
|
||||||
qmlprofilereventview.h \
|
qmlprofilereventview.h \
|
||||||
qmlprofilereventtypes.h
|
qmlprofilereventtypes.h \
|
||||||
|
qmlprofilerruncontrolfactory.h
|
||||||
|
|
||||||
RESOURCES += \
|
RESOURCES += \
|
||||||
qml/qml.qrc
|
qml/qml.qrc
|
||||||
|
|||||||
@@ -34,7 +34,7 @@
|
|||||||
#include "qmlprofilerplugin.h"
|
#include "qmlprofilerplugin.h"
|
||||||
|
|
||||||
#include "qmlprofilertool.h"
|
#include "qmlprofilertool.h"
|
||||||
#include "qmlprojectanalyzerruncontrolfactory.h"
|
#include "qmlprofilerruncontrolfactory.h"
|
||||||
|
|
||||||
#include <analyzerbase/analyzermanager.h>
|
#include <analyzerbase/analyzermanager.h>
|
||||||
|
|
||||||
@@ -49,7 +49,7 @@ bool QmlProfilerPlugin::initialize(const QStringList &arguments, QString *errorS
|
|||||||
{
|
{
|
||||||
Q_UNUSED(arguments)
|
Q_UNUSED(arguments)
|
||||||
Q_UNUSED(errorString)
|
Q_UNUSED(errorString)
|
||||||
addAutoReleasedObject(new QmlProjectAnalyzerRunControlFactory());
|
addAutoReleasedObject(new QmlProfilerRunControlFactory());
|
||||||
StartModes modes;
|
StartModes modes;
|
||||||
// They are handled the same actually.
|
// They are handled the same actually.
|
||||||
//modes.append(StartMode(StartRemote));
|
//modes.append(StartMode(StartRemote));
|
||||||
|
|||||||
@@ -31,7 +31,7 @@
|
|||||||
**
|
**
|
||||||
**************************************************************************/
|
**************************************************************************/
|
||||||
|
|
||||||
#include "qmlprojectanalyzerruncontrolfactory.h"
|
#include "qmlprofilerruncontrolfactory.h"
|
||||||
#include "qmlprojectmanager/qmlprojectrunconfiguration.h"
|
#include "qmlprojectmanager/qmlprojectrunconfiguration.h"
|
||||||
|
|
||||||
#include <analyzerbase/analyzerstartparameters.h>
|
#include <analyzerbase/analyzerstartparameters.h>
|
||||||
@@ -56,13 +56,13 @@ using namespace ProjectExplorer;
|
|||||||
using namespace QmlProfiler::Internal;
|
using namespace QmlProfiler::Internal;
|
||||||
using namespace QmlProjectManager;
|
using namespace QmlProjectManager;
|
||||||
|
|
||||||
QmlProjectAnalyzerRunControlFactory::QmlProjectAnalyzerRunControlFactory(QObject *parent)
|
QmlProfilerRunControlFactory::QmlProfilerRunControlFactory(QObject *parent)
|
||||||
: IRunControlFactory(parent)
|
: IRunControlFactory(parent)
|
||||||
{
|
{
|
||||||
setObjectName(QLatin1String("QmlProjectAnalyzerRunControlFactory"));
|
setObjectName(QLatin1String("QmlProfilerRunControlFactory"));
|
||||||
}
|
}
|
||||||
|
|
||||||
bool QmlProjectAnalyzerRunControlFactory::canRun(RunConfiguration *runConfiguration, const QString &mode) const
|
bool QmlProfilerRunControlFactory::canRun(RunConfiguration *runConfiguration, const QString &mode) const
|
||||||
{
|
{
|
||||||
// FIXME: Should this just accept all mode == QLatin1String("QmlProfiler"); ?
|
// FIXME: Should this just accept all mode == QLatin1String("QmlProfiler"); ?
|
||||||
if (qobject_cast<QmlProjectRunConfiguration *>(runConfiguration))
|
if (qobject_cast<QmlProjectRunConfiguration *>(runConfiguration))
|
||||||
@@ -76,7 +76,7 @@ bool QmlProjectAnalyzerRunControlFactory::canRun(RunConfiguration *runConfigurat
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
RunControl *QmlProjectAnalyzerRunControlFactory::create(RunConfiguration *runConfiguration, const QString &mode)
|
RunControl *QmlProfilerRunControlFactory::create(RunConfiguration *runConfiguration, const QString &mode)
|
||||||
{
|
{
|
||||||
QTC_ASSERT(canRun(runConfiguration, mode), return 0);
|
QTC_ASSERT(canRun(runConfiguration, mode), return 0);
|
||||||
AnalyzerStartParameters sp;
|
AnalyzerStartParameters sp;
|
||||||
@@ -131,17 +131,17 @@ RunControl *QmlProjectAnalyzerRunControlFactory::create(RunConfiguration *runCon
|
|||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
|
|
||||||
QString QmlProjectAnalyzerRunControlFactory::displayName() const
|
QString QmlProfilerRunControlFactory::displayName() const
|
||||||
{
|
{
|
||||||
return tr("QML Profiler");
|
return tr("QML Profiler");
|
||||||
}
|
}
|
||||||
|
|
||||||
IRunConfigurationAspect *QmlProjectAnalyzerRunControlFactory::createRunConfigurationAspect()
|
IRunConfigurationAspect *QmlProfilerRunControlFactory::createRunConfigurationAspect()
|
||||||
{
|
{
|
||||||
return new AnalyzerProjectSettings;
|
return new AnalyzerProjectSettings;
|
||||||
}
|
}
|
||||||
|
|
||||||
RunConfigWidget *QmlProjectAnalyzerRunControlFactory::createConfigurationWidget(RunConfiguration *runConfiguration)
|
RunConfigWidget *QmlProfilerRunControlFactory::createConfigurationWidget(RunConfiguration *runConfiguration)
|
||||||
{
|
{
|
||||||
QmlProjectManager::QmlProjectRunConfiguration *localRc =
|
QmlProjectManager::QmlProjectRunConfiguration *localRc =
|
||||||
qobject_cast<QmlProjectManager::QmlProjectRunConfiguration *>(runConfiguration);
|
qobject_cast<QmlProjectManager::QmlProjectRunConfiguration *>(runConfiguration);
|
||||||
@@ -31,24 +31,23 @@
|
|||||||
**
|
**
|
||||||
**************************************************************************/
|
**************************************************************************/
|
||||||
|
|
||||||
#ifndef QMLPROJECTANALYZERRUNCONTROLFACTORY_H
|
#ifndef QMLPROFILERRUNCONTROLFACTORY_H
|
||||||
#define QMLPROJECTANALYZERRUNCONTROLFACTORY_H
|
#define QMLPROFILERRUNCONTROLFACTORY_H
|
||||||
|
|
||||||
#include <analyzerbase/analyzerruncontrol.h>
|
#include <analyzerbase/analyzerruncontrol.h>
|
||||||
//#include <analyzerbase/analyzerruncontrolfactory.h>
|
|
||||||
#include <projectexplorer/runconfiguration.h>
|
#include <projectexplorer/runconfiguration.h>
|
||||||
|
|
||||||
namespace QmlProfiler {
|
namespace QmlProfiler {
|
||||||
namespace Internal {
|
namespace Internal {
|
||||||
|
|
||||||
class QmlProjectAnalyzerRunControlFactory : public ProjectExplorer::IRunControlFactory
|
class QmlProfilerRunControlFactory : public ProjectExplorer::IRunControlFactory
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
typedef ProjectExplorer::RunConfiguration RunConfiguration;
|
typedef ProjectExplorer::RunConfiguration RunConfiguration;
|
||||||
|
|
||||||
QmlProjectAnalyzerRunControlFactory(QObject *parent = 0);
|
QmlProfilerRunControlFactory(QObject *parent = 0);
|
||||||
|
|
||||||
// IRunControlFactory implementation
|
// IRunControlFactory implementation
|
||||||
QString displayName() const;
|
QString displayName() const;
|
||||||
@@ -64,4 +63,4 @@ signals:
|
|||||||
} // namespace Internal
|
} // namespace Internal
|
||||||
} // namespace QmlProfiler
|
} // namespace QmlProfiler
|
||||||
|
|
||||||
#endif // QMLPROJECTANALYZERRUNCONTROLFACTORY_H
|
#endif // QMLPROFILERRUNCONTROLFACTORY_H
|
||||||
Reference in New Issue
Block a user