forked from qt-creator/qt-creator
AutoTools: Use aspects in build steps
Less code. And there's more room for consolidation. Change-Id: Iccdaf5570155ec2783b7cf6528d3887f6efd5dbb Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -28,17 +28,11 @@
|
||||
#pragma once
|
||||
|
||||
#include <projectexplorer/abstractprocessstep.h>
|
||||
|
||||
QT_BEGIN_NAMESPACE
|
||||
class QLineEdit;
|
||||
QT_END_NAMESPACE
|
||||
#include <projectexplorer/projectconfigurationaspects.h>
|
||||
|
||||
namespace AutotoolsProjectManager {
|
||||
namespace Internal {
|
||||
|
||||
class AutotoolsProject;
|
||||
class ConfigureStepConfigWidget;
|
||||
|
||||
//////////////////////////////////
|
||||
// ConfigureStepFactory Class
|
||||
//////////////////////////////////
|
||||
@@ -69,8 +63,6 @@ public:
|
||||
class ConfigureStep : public ProjectExplorer::AbstractProcessStep
|
||||
{
|
||||
Q_OBJECT
|
||||
friend class ConfigureStepFactory;
|
||||
friend class ConfigureStepConfigWidget;
|
||||
|
||||
public:
|
||||
explicit ConfigureStep(ProjectExplorer::BuildStepList *bsl);
|
||||
@@ -79,43 +71,16 @@ public:
|
||||
void run(QFutureInterface<bool> &fi) override;
|
||||
ProjectExplorer::BuildStepConfigWidget *createConfigWidget() override;
|
||||
bool immutable() const override;
|
||||
QString additionalArguments() const;
|
||||
QVariantMap toMap() const override;
|
||||
|
||||
void setAdditionalArguments(const QString &list);
|
||||
void notifyBuildDirectoryChanged();
|
||||
|
||||
signals:
|
||||
void additionalArgumentsChanged(const QString &);
|
||||
void buildDirectoryChanged();
|
||||
|
||||
private:
|
||||
bool fromMap(const QVariantMap &map) override;
|
||||
|
||||
QString m_additionalArguments;
|
||||
bool m_runConfigure = false;
|
||||
};
|
||||
|
||||
/////////////////////////////////////
|
||||
// ConfigureStepConfigWidget class
|
||||
/////////////////////////////////////
|
||||
/**
|
||||
* @brief Implementation of the ProjectExplorer::BuildStepConfigWidget interface.
|
||||
*
|
||||
* Allows to configure a configure step in the GUI.
|
||||
*/
|
||||
class ConfigureStepConfigWidget : public ProjectExplorer::BuildStepConfigWidget
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
public:
|
||||
ConfigureStepConfigWidget(ConfigureStep *configureStep);
|
||||
|
||||
private:
|
||||
void updateDetails();
|
||||
|
||||
ConfigureStep *m_configureStep;
|
||||
QLineEdit *m_additionalArguments;
|
||||
ProjectExplorer::BaseStringAspect *m_additionalArgumentsAspect = nullptr;
|
||||
bool m_runConfigure = false;
|
||||
QPointer<ProjectExplorer::BuildStepConfigWidget> m_widget;
|
||||
};
|
||||
|
||||
} // namespace Internal
|
||||
|
||||
Reference in New Issue
Block a user