forked from qt-creator/qt-creator
Python: Code cosmetics
Remove some unnecessary #include and use a recently introduced RunConfiguration::builtTargetInfo() convenience function. Change-Id: I76750fd66ae2c268b68d225c62aad7d880256d07 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -35,9 +35,6 @@
|
|||||||
#include <coreplugin/id.h>
|
#include <coreplugin/id.h>
|
||||||
#include <coreplugin/editormanager/editormanager.h>
|
#include <coreplugin/editormanager/editormanager.h>
|
||||||
|
|
||||||
#include <extensionsystem/pluginmanager.h>
|
|
||||||
|
|
||||||
#include <projectexplorer/applicationlauncher.h>
|
|
||||||
#include <projectexplorer/buildtargetinfo.h>
|
#include <projectexplorer/buildtargetinfo.h>
|
||||||
#include <projectexplorer/kitmanager.h>
|
#include <projectexplorer/kitmanager.h>
|
||||||
#include <projectexplorer/localenvironmentaspect.h>
|
#include <projectexplorer/localenvironmentaspect.h>
|
||||||
@@ -58,9 +55,7 @@
|
|||||||
#include <utils/qtcprocess.h>
|
#include <utils/qtcprocess.h>
|
||||||
#include <utils/utilsicons.h>
|
#include <utils/utilsicons.h>
|
||||||
|
|
||||||
#include <QCoreApplication>
|
|
||||||
#include <QDir>
|
#include <QDir>
|
||||||
#include <QFormLayout>
|
|
||||||
#include <QRegExp>
|
#include <QRegExp>
|
||||||
#include <QRegularExpression>
|
#include <QRegularExpression>
|
||||||
#include <QRegularExpressionMatch>
|
#include <QRegularExpressionMatch>
|
||||||
@@ -78,9 +73,6 @@ const char PythonMimeType[] = "text/x-python-project"; // ### FIXME
|
|||||||
const char PythonProjectId[] = "PythonProject";
|
const char PythonProjectId[] = "PythonProject";
|
||||||
const char PythonErrorTaskCategory[] = "Task.Category.Python";
|
const char PythonErrorTaskCategory[] = "Task.Category.Python";
|
||||||
|
|
||||||
class PythonRunConfiguration;
|
|
||||||
class PythonProjectFile;
|
|
||||||
|
|
||||||
class PythonProject : public Project
|
class PythonProject : public Project
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
@@ -287,7 +279,7 @@ PythonRunConfiguration::PythonRunConfiguration(Target *target, Core::Id id)
|
|||||||
|
|
||||||
void PythonRunConfiguration::updateTargetInformation()
|
void PythonRunConfiguration::updateTargetInformation()
|
||||||
{
|
{
|
||||||
BuildTargetInfo bti = target()->applicationTargets().buildTargetInfo(buildKey());
|
const BuildTargetInfo bti = buildTargetInfo();
|
||||||
const QString script = bti.targetFilePath.toString();
|
const QString script = bti.targetFilePath.toString();
|
||||||
setDefaultDisplayName(tr("Run %1").arg(script));
|
setDefaultDisplayName(tr("Run %1").arg(script));
|
||||||
extraAspect<MainScriptAspect>()->setValue(script);
|
extraAspect<MainScriptAspect>()->setValue(script);
|
||||||
|
Reference in New Issue
Block a user