aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2019-06-13 17:03:56 +0200
committerhjk <hjk@qt.io>2019-06-14 13:00:25 +0000
commit77e8e1707c7223fc4905058f531e83e6788ad845 (patch)
tree23cde0178033b9062ab12b8653c6ee95161de494 /src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp
parent7ceb26defc49ad281369ed87b45e46fe26268167 (diff)
RemoteLinux: Move deployservice ownership to AbstractRemoteLinuxDeployStep
Change-Id: I12cfa0d2cdb171d381e6fde6b0e71fc0c098d746 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp')
-rw-r--r--src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp27
1 files changed, 5 insertions, 22 deletions
diff --git a/src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp b/src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp
index 35a80e005f9..61aebbe893b 100644
--- a/src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp
+++ b/src/plugins/remotelinux/remotelinuxcustomcommanddeploymentstep.cpp
@@ -31,20 +31,11 @@
using namespace ProjectExplorer;
namespace RemoteLinux {
-namespace Internal {
-
-class RemoteLinuxCustomCommandDeploymentStepPrivate
-{
-public:
- RemoteLinuxCustomCommandDeployService service;
-};
-
-} // namespace Internal
RemoteLinuxCustomCommandDeploymentStep::RemoteLinuxCustomCommandDeploymentStep(BuildStepList *bsl)
: AbstractRemoteLinuxDeployStep(bsl, stepId())
{
- d = new Internal::RemoteLinuxCustomCommandDeploymentStepPrivate;
+ auto service = createDeployService<RemoteLinuxCustomCommandDeployService>();
auto commandLine = addAspect<BaseStringAspect>();
commandLine->setSettingsKey("RemoteLinuxCustomCommandDeploymentStep.CommandLine");
@@ -53,21 +44,13 @@ RemoteLinuxCustomCommandDeploymentStep::RemoteLinuxCustomCommandDeploymentStep(B
setDefaultDisplayName(displayName());
- setInternalInitializer([this, commandLine] {
- d->service.setCommandLine(commandLine->value().trimmed());
- return d->service.isDeploymentPossible();
+ setInternalInitializer([service, commandLine] {
+ service->setCommandLine(commandLine->value().trimmed());
+ return service->isDeploymentPossible();
});
}
-RemoteLinuxCustomCommandDeploymentStep::~RemoteLinuxCustomCommandDeploymentStep()
-{
- delete d;
-}
-
-AbstractRemoteLinuxDeployService *RemoteLinuxCustomCommandDeploymentStep::deployService() const
-{
- return &d->service;
-}
+RemoteLinuxCustomCommandDeploymentStep::~RemoteLinuxCustomCommandDeploymentStep() = default;
Core::Id RemoteLinuxCustomCommandDeploymentStep::stepId()
{