RemoteLinux: Unexport some classes

And move them into Internal namespace.

Change-Id: Ic3cc92b8250413f46f597f99fe0f1e4c8ef68950
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Jarek Kobus
2023-07-21 09:21:20 +02:00
parent d8ffbfb3ff
commit ef005dd56e
8 changed files with 22 additions and 33 deletions

View File

@@ -952,7 +952,7 @@ LinuxDevice::LinuxDevice()
setSshParameters(sshParams); setSshParameters(sshParams);
addDeviceAction({Tr::tr("Deploy Public Key..."), [](const IDevice::Ptr &device, QWidget *parent) { addDeviceAction({Tr::tr("Deploy Public Key..."), [](const IDevice::Ptr &device, QWidget *parent) {
if (auto d = PublicKeyDeploymentDialog::createDialog(device, parent)) { if (auto d = Internal::PublicKeyDeploymentDialog::createDialog(device, parent)) {
d->exec(); d->exec();
delete d; delete d;
} }

View File

@@ -30,7 +30,7 @@
using namespace ProjectExplorer; using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
namespace RemoteLinux { namespace RemoteLinux::Internal {
class MakeInstallStep : public MakeStep class MakeInstallStep : public MakeStep
{ {
@@ -275,4 +275,4 @@ MakeInstallStepFactory::MakeInstallStepFactory()
setDisplayName(Tr::tr("Install into temporary host directory")); setDisplayName(Tr::tr("Install into temporary host directory"));
} }
} // RemoteLinux } // RemoteLinux::Internal

View File

@@ -3,17 +3,14 @@
#pragma once #pragma once
#include "remotelinux_export.h"
#include <projectexplorer/buildstep.h> #include <projectexplorer/buildstep.h>
namespace RemoteLinux { namespace RemoteLinux::Internal {
class REMOTELINUX_EXPORT MakeInstallStepFactory class MakeInstallStepFactory : public ProjectExplorer::BuildStepFactory
: public ProjectExplorer::BuildStepFactory
{ {
public: public:
MakeInstallStepFactory(); MakeInstallStepFactory();
}; };
} // namespace RemoteLinux } // namespace RemoteLinux::Internal

View File

@@ -17,8 +17,7 @@
using namespace ProjectExplorer; using namespace ProjectExplorer;
using namespace Utils; using namespace Utils;
namespace RemoteLinux { namespace RemoteLinux::Internal {
namespace Internal {
class PublicKeyDeploymentDialogPrivate class PublicKeyDeploymentDialogPrivate
{ {
@@ -26,9 +25,6 @@ public:
Process m_process; Process m_process;
bool m_done; bool m_done;
}; };
} // namespace Internal;
using namespace Internal;
PublicKeyDeploymentDialog *PublicKeyDeploymentDialog::createDialog( PublicKeyDeploymentDialog *PublicKeyDeploymentDialog::createDialog(
const IDevice::ConstPtr &deviceConfig, QWidget *parent) const IDevice::ConstPtr &deviceConfig, QWidget *parent)
@@ -128,4 +124,4 @@ void PublicKeyDeploymentDialog::handleDeploymentDone(bool succeeded, const QStri
d->m_done = true; d->m_done = true;
} }
} // namespace RemoteLinux } // namespace RemoteLinux::Internal

View File

@@ -3,24 +3,23 @@
#pragma once #pragma once
#include "remotelinux_export.h"
#include <projectexplorer/devicesupport/idevicefwd.h> #include <projectexplorer/devicesupport/idevicefwd.h>
#include <QProgressDialog> #include <QProgressDialog>
namespace Utils { class FilePath; } namespace Utils { class FilePath; }
namespace RemoteLinux { namespace RemoteLinux::Internal {
namespace Internal { class PublicKeyDeploymentDialogPrivate; }
class REMOTELINUX_EXPORT PublicKeyDeploymentDialog : public QProgressDialog class PublicKeyDeploymentDialogPrivate;
class PublicKeyDeploymentDialog : public QProgressDialog
{ {
Q_OBJECT Q_OBJECT
public: public:
// Asks for public key and returns null if the file dialog is canceled. // Asks for public key and returns null if the file dialog is canceled.
static PublicKeyDeploymentDialog *createDialog(const ProjectExplorer::IDeviceConstPtr &deviceConfig, static PublicKeyDeploymentDialog *createDialog(
QWidget *parent = nullptr); const ProjectExplorer::IDeviceConstPtr &deviceConfig, QWidget *parent = nullptr);
PublicKeyDeploymentDialog(const ProjectExplorer::IDeviceConstPtr &deviceConfig, PublicKeyDeploymentDialog(const ProjectExplorer::IDeviceConstPtr &deviceConfig,
const Utils::FilePath &publicKeyFileName, QWidget *parent = nullptr); const Utils::FilePath &publicKeyFileName, QWidget *parent = nullptr);
@@ -33,4 +32,4 @@ private:
Internal::PublicKeyDeploymentDialogPrivate * const d; Internal::PublicKeyDeploymentDialogPrivate * const d;
}; };
} // namespace RemoteLinux } // namespace RemoteLinux::Internal

View File

@@ -26,7 +26,7 @@ using namespace ProjectExplorer;
using namespace Tasking; using namespace Tasking;
using namespace Utils; using namespace Utils;
namespace RemoteLinux { namespace RemoteLinux::Internal {
// RsyncDeployStep // RsyncDeployStep
@@ -205,4 +205,4 @@ RsyncDeployStepFactory::RsyncDeployStepFactory()
setDisplayName(Tr::tr("Deploy files via rsync")); setDisplayName(Tr::tr("Deploy files via rsync"));
} }
} // RemoteLinux } // RemoteLinux::Internal

View File

@@ -3,17 +3,14 @@
#pragma once #pragma once
#include "remotelinux_export.h"
#include <projectexplorer/buildstep.h> #include <projectexplorer/buildstep.h>
namespace RemoteLinux { namespace RemoteLinux::Internal {
class REMOTELINUX_EXPORT RsyncDeployStepFactory class RsyncDeployStepFactory : public ProjectExplorer::BuildStepFactory
: public ProjectExplorer::BuildStepFactory
{ {
public: public:
RsyncDeployStepFactory(); RsyncDeployStepFactory();
}; };
} // namespace RemoteLinux } // namespace RemoteLinux::Internal

View File

@@ -118,8 +118,8 @@ public:
m_keyFileChooser.setPromptDialogTitle(Tr::tr("Choose a Private Key File")); m_keyFileChooser.setPromptDialogTitle(Tr::tr("Choose a Private Key File"));
auto const deployButton = new QPushButton(Tr::tr("Deploy Public Key"), this); auto const deployButton = new QPushButton(Tr::tr("Deploy Public Key"), this);
connect(deployButton, &QPushButton::clicked, this, [this] { connect(deployButton, &QPushButton::clicked, this, [this] {
PublicKeyDeploymentDialog dlg(m_device, Internal::PublicKeyDeploymentDialog dlg(
m_keyFileChooser.filePath().stringAppended(".pub"), this); m_device, m_keyFileChooser.filePath().stringAppended(".pub"), this);
m_iconLabel.setPixmap((dlg.exec() == QDialog::Accepted ? Icons::OK : Icons::BROKEN).pixmap()); m_iconLabel.setPixmap((dlg.exec() == QDialog::Accepted ? Icons::OK : Icons::BROKEN).pixmap());
}); });
auto const createButton = new QPushButton(Tr::tr("Create New Key Pair"), this); auto const createButton = new QPushButton(Tr::tr("Create New Key Pair"), this);