summaryrefslogtreecommitdiff
path: root/src/plugins
diff options
context:
space:
mode:
authorChristian Kandeler <christian.kandeler@nokia.com>2012-06-05 17:56:19 +0200
committerChristian Kandeler <christian.kandeler@nokia.com>2012-06-06 09:26:11 +0200
commit291e23d0e1cefcdc5197f7333182f6fb87b52f38 (patch)
treea8ab2c1eb21679ec01020aa459e9d6eac3c96c5b /src/plugins
parent7339ab60e64f88f5c1e08e36c4c8d456ba8b10e2 (diff)
downloadqt-creator-291e23d0e1cefcdc5197f7333182f6fb87b52f38.tar.gz
RemoteLinux: Make disk space check step extensible.
Also fix cloning. Change-Id: I32db1fd2a98486e2871c01d4c0f9aebd2f262924 Reviewed-by: Nikolai Kosjar <nikolai.kosjar@nokia.com>
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.cpp10
-rw-r--r--src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.h6
2 files changed, 10 insertions, 6 deletions
diff --git a/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.cpp b/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.cpp
index 81afdbedd4..738d8aaf34 100644
--- a/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.cpp
+++ b/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.cpp
@@ -95,16 +95,20 @@ public:
} // namespace Internal
-RemoteLinuxCheckForFreeDiskSpaceStep::RemoteLinuxCheckForFreeDiskSpaceStep(BuildStepList *bsl)
- : AbstractRemoteLinuxDeployStep(bsl, stepId())
+RemoteLinuxCheckForFreeDiskSpaceStep::RemoteLinuxCheckForFreeDiskSpaceStep(BuildStepList *bsl, Core::Id id)
+ : AbstractRemoteLinuxDeployStep(bsl, id)
{
ctor();
+ setPathToCheck(QLatin1String("/"));
+ setRequiredSpaceInBytes(5*1024*1024);
}
RemoteLinuxCheckForFreeDiskSpaceStep::RemoteLinuxCheckForFreeDiskSpaceStep(BuildStepList *bsl,
RemoteLinuxCheckForFreeDiskSpaceStep *other) : AbstractRemoteLinuxDeployStep(bsl, other)
{
ctor();
+ setPathToCheck(other->pathToCheck());
+ setRequiredSpaceInBytes(other->requiredSpaceInBytes());
}
RemoteLinuxCheckForFreeDiskSpaceStep::~RemoteLinuxCheckForFreeDiskSpaceStep()
@@ -116,8 +120,6 @@ void RemoteLinuxCheckForFreeDiskSpaceStep::ctor()
{
d = new Internal::RemoteLinuxCheckForFreeDiskSpaceStepPrivate;
setDefaultDisplayName(stepDisplayName());
- d->pathToCheck = QLatin1String("/");
- d->requiredSpaceInBytes = 5*1024*1024;
}
void RemoteLinuxCheckForFreeDiskSpaceStep::setPathToCheck(const QString &path)
diff --git a/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.h b/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.h
index 561a95704a..26c342c070 100644
--- a/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.h
+++ b/src/plugins/remotelinux/remotelinuxcheckforfreediskspacestep.h
@@ -41,7 +41,8 @@ class REMOTELINUX_EXPORT RemoteLinuxCheckForFreeDiskSpaceStep : public AbstractR
{
Q_OBJECT
public:
- explicit RemoteLinuxCheckForFreeDiskSpaceStep(ProjectExplorer::BuildStepList *bsl);
+ explicit RemoteLinuxCheckForFreeDiskSpaceStep(ProjectExplorer::BuildStepList *bsl,
+ Core::Id id = stepId());
RemoteLinuxCheckForFreeDiskSpaceStep(ProjectExplorer::BuildStepList *bsl,
RemoteLinuxCheckForFreeDiskSpaceStep *other);
~RemoteLinuxCheckForFreeDiskSpaceStep();
@@ -55,7 +56,7 @@ public:
static Core::Id stepId();
static QString stepDisplayName();
-private:
+protected:
bool fromMap(const QVariantMap &map);
QVariantMap toMap() const;
ProjectExplorer::BuildStepConfigWidget *createConfigWidget();
@@ -63,6 +64,7 @@ private:
bool initInternal(QString *error);
AbstractRemoteLinuxDeployService *deployService() const;
+private:
void ctor();
Internal::RemoteLinuxCheckForFreeDiskSpaceStepPrivate *d;