diff --git a/src/libs/libs.pro b/src/libs/libs.pro index 719cbe10fef6e2769c8bd57db3b447636cfb028d..f33e687774f5c5803230b366b97bd5c60038b35e 100644 --- a/src/libs/libs.pro +++ b/src/libs/libs.pro @@ -3,6 +3,7 @@ CONFIG += ordered QT += core gui SUBDIRS = \ + 3rdparty \ qtconcurrent \ aggregation \ extensionsystem \ @@ -13,8 +14,7 @@ SUBDIRS = \ qmljs \ glsl \ qmleditorwidgets \ - symbianutils \ - 3rdparty + symbianutils # Windows: Compile Qt Creator CDB extension if Debugging tools can be detected. win32 { diff --git a/src/plugins/coreplugin/ssh/sftpchannel.cpp b/src/libs/utils/ssh/sftpchannel.cpp similarity index 98% rename from src/plugins/coreplugin/ssh/sftpchannel.cpp rename to src/libs/utils/ssh/sftpchannel.cpp index e61d27a22651cf52ed79cbc0da653768091bdac9..1fb19e0740d30e12473e57d2412ea50549daa250 100644 --- a/src/plugins/coreplugin/ssh/sftpchannel.cpp +++ b/src/libs/utils/ssh/sftpchannel.cpp @@ -41,7 +41,7 @@ #include <QtCore/QDir> #include <QtCore/QFile> -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -70,10 +70,10 @@ SftpChannel::SftpChannel(quint32 channelId, Qt::QueuedConnection); connect(d, SIGNAL(initializationFailed(QString)), this, SIGNAL(initializationFailed(QString)), Qt::QueuedConnection); - connect(d, SIGNAL(dataAvailable(Core::SftpJobId, QString)), this, - SIGNAL(dataAvailable(Core::SftpJobId, QString)), Qt::QueuedConnection); - connect(d, SIGNAL(finished(Core::SftpJobId,QString)), this, - SIGNAL(finished(Core::SftpJobId,QString)), Qt::QueuedConnection); + connect(d, SIGNAL(dataAvailable(Utils::SftpJobId, QString)), this, + SIGNAL(dataAvailable(Utils::SftpJobId, QString)), Qt::QueuedConnection); + connect(d, SIGNAL(finished(Utils::SftpJobId,QString)), this, + SIGNAL(finished(Utils::SftpJobId,QString)), Qt::QueuedConnection); connect(d, SIGNAL(closed()), this, SIGNAL(closed()), Qt::QueuedConnection); } @@ -882,4 +882,4 @@ void SftpChannelPrivate::spawnReadRequests(const SftpDownload::Ptr &job) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sftpchannel.h b/src/libs/utils/ssh/sftpchannel.h similarity index 94% rename from src/plugins/coreplugin/ssh/sftpchannel.h rename to src/libs/utils/ssh/sftpchannel.h index 0cbbf9c0cc5c060514d9f639fa70ff54ac2a510f..d347f9ed6850f0f0b9f08077e03fedcb1d868f9a 100644 --- a/src/plugins/coreplugin/ssh/sftpchannel.h +++ b/src/libs/utils/ssh/sftpchannel.h @@ -37,14 +37,14 @@ #include "sftpdefs.h" #include "sftpincomingpacket_p.h" -#include <coreplugin/core_global.h> +#include <utils/utils_global.h> #include <QtCore/QByteArray> #include <QtCore/QObject> #include <QtCore/QSharedPointer> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { class SftpChannelPrivate; @@ -71,7 +71,7 @@ class SshSendFacility; * non-empty error string. * Note that directory names must not have a trailing slash. */ -class CORE_EXPORT SftpChannel : public QObject +class QTCREATOR_UTILS_EXPORT SftpChannel : public QObject { Q_OBJECT @@ -108,14 +108,14 @@ signals: void closed(); // error.isEmpty <=> finished successfully - void finished(Core::SftpJobId job, const QString &error = QString()); + void finished(Utils::SftpJobId job, const QString &error = QString()); /* * This signal is only emitted by the "List Directory" operation, * one file at a time. // TODO: Also emit for each file copied by uploadDir(). */ - void dataAvailable(Core::SftpJobId job, const QString &data); + void dataAvailable(Utils::SftpJobId job, const QString &data); private: SftpChannel(quint32 channelId, Internal::SshSendFacility &sendFacility); @@ -123,6 +123,6 @@ private: Internal::SftpChannelPrivate *d; }; -} // namespace Core +} // namespace Utils #endif // SFTPCHANNEL_H diff --git a/src/plugins/coreplugin/ssh/sftpchannel_p.h b/src/libs/utils/ssh/sftpchannel_p.h similarity index 95% rename from src/plugins/coreplugin/ssh/sftpchannel_p.h rename to src/libs/utils/ssh/sftpchannel_p.h index 60cb5d24d219229f40f4235f71357655c1443d93..13c8a1d0aeb60ecd9a2007f29c4e1f8d25e02da9 100644 --- a/src/plugins/coreplugin/ssh/sftpchannel_p.h +++ b/src/libs/utils/ssh/sftpchannel_p.h @@ -43,14 +43,14 @@ #include <QtCore/QByteArray> #include <QtCore/QMap> -namespace Core { +namespace Utils { class SftpChannel; namespace Internal { class SftpChannelPrivate : public AbstractSshChannel { Q_OBJECT - friend class Core::SftpChannel; + friend class Utils::SftpChannel; public: enum SftpState { Inactive, SubsystemRequested, InitSent, Initialized }; @@ -64,8 +64,8 @@ signals: void initialized(); void initializationFailed(const QString &reason); void closed(); - void finished(Core::SftpJobId job, const QString &error = QString()); - void dataAvailable(Core::SftpJobId job, const QString &data); + void finished(Utils::SftpJobId job, const QString &error = QString()); + void dataAvailable(Utils::SftpJobId job, const QString &data); private: typedef QMap<SftpJobId, AbstractSftpOperation::Ptr> JobMap; @@ -128,6 +128,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SFTPCHANNEL_P_H diff --git a/src/plugins/coreplugin/ssh/sftpdefs.cpp b/src/libs/utils/ssh/sftpdefs.cpp similarity index 96% rename from src/plugins/coreplugin/ssh/sftpdefs.cpp rename to src/libs/utils/ssh/sftpdefs.cpp index dd50f2ac7227cea2d1e27e9b9c7f839c33161f3a..61c810e53b934116866da25cb8a527696e41c4be 100644 --- a/src/plugins/coreplugin/ssh/sftpdefs.cpp +++ b/src/libs/utils/ssh/sftpdefs.cpp @@ -33,4 +33,4 @@ #include "sftpdefs.h" -namespace Core { const SftpJobId SftpInvalidJob = 0; } +namespace Utils { const SftpJobId SftpInvalidJob = 0; } diff --git a/src/plugins/coreplugin/ssh/sftpdefs.h b/src/libs/utils/ssh/sftpdefs.h similarity index 92% rename from src/plugins/coreplugin/ssh/sftpdefs.h rename to src/libs/utils/ssh/sftpdefs.h index ccf3c1c4f0a721f119eb6e4161072b56a9d66d10..4a268ebf37502167706d3ee3f04d411598e797d2 100644 --- a/src/plugins/coreplugin/ssh/sftpdefs.h +++ b/src/libs/utils/ssh/sftpdefs.h @@ -34,19 +34,19 @@ #ifndef SFTPDEFS_H #define SFTPDEFS_H -#include <coreplugin/core_global.h> +#include <utils/utils_global.h> #include <QtCore/QtGlobal> -namespace Core { +namespace Utils { typedef quint32 SftpJobId; -CORE_EXPORT extern const SftpJobId SftpInvalidJob; +QTCREATOR_UTILS_EXPORT extern const SftpJobId SftpInvalidJob; enum SftpOverwriteMode { SftpOverwriteExisting, SftpAppendToExisting, SftpSkipExisting }; -} // namespace Core +} // namespace Utils #endif // SFTPDEFS_H diff --git a/src/plugins/coreplugin/ssh/sftpincomingpacket.cpp b/src/libs/utils/ssh/sftpincomingpacket.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sftpincomingpacket.cpp rename to src/libs/utils/ssh/sftpincomingpacket.cpp index 1df7fbe69c0e058c4011b160fa4ef1bc0c27f0fc..72ca814adec621f0ba2d0b54602b8d3857057e93 100644 --- a/src/plugins/coreplugin/ssh/sftpincomingpacket.cpp +++ b/src/libs/utils/ssh/sftpincomingpacket.cpp @@ -36,7 +36,7 @@ #include "sshexception_p.h" #include "sshpacketparser_p.h" -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -231,4 +231,4 @@ SftpFileAttributes SftpIncomingPacket::asFileAttributes(quint32 &offset) const } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sftpincomingpacket_p.h b/src/libs/utils/ssh/sftpincomingpacket_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sftpincomingpacket_p.h rename to src/libs/utils/ssh/sftpincomingpacket_p.h index d1248c7e87f66bf407b60b9a78404813bc223f10..ab8defcaff8453196dcb6965c928f109fe90c879 100644 --- a/src/plugins/coreplugin/ssh/sftpincomingpacket_p.h +++ b/src/libs/utils/ssh/sftpincomingpacket_p.h @@ -36,7 +36,7 @@ #include "sftppacket_p.h" -namespace Core { +namespace Utils { namespace Internal { struct SftpHandleResponse { @@ -110,6 +110,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SFTPINCOMINGPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sftpoperation.cpp b/src/libs/utils/ssh/sftpoperation.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sftpoperation.cpp rename to src/libs/utils/ssh/sftpoperation.cpp index edecb5710bda0e7d4b573850319b3f56719e3283..81a32c72fbf104e06ca7257f5378f254f28fa479 100644 --- a/src/plugins/coreplugin/ssh/sftpoperation.cpp +++ b/src/libs/utils/ssh/sftpoperation.cpp @@ -37,7 +37,7 @@ #include <QtCore/QFile> -namespace Core { +namespace Utils { namespace Internal { AbstractSftpOperation::AbstractSftpOperation(SftpJobId jobId) : jobId(jobId) @@ -184,4 +184,4 @@ SftpOutgoingPacket &SftpUploadFile::initialPacket(SftpOutgoingPacket &packet) SftpUploadDir::~SftpUploadDir() {} } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sftpoperation_p.h b/src/libs/utils/ssh/sftpoperation_p.h similarity index 99% rename from src/plugins/coreplugin/ssh/sftpoperation_p.h rename to src/libs/utils/ssh/sftpoperation_p.h index c1934e81b02a41aa76a720a60435410c239ac8e7..0cda2ac843eae96337928535ed602b80a0119fa5 100644 --- a/src/plugins/coreplugin/ssh/sftpoperation_p.h +++ b/src/libs/utils/ssh/sftpoperation_p.h @@ -45,7 +45,7 @@ QT_BEGIN_NAMESPACE class QFile; QT_END_NAMESPACE -namespace Core { +namespace Utils { namespace Internal { class SftpOutgoingPacket; @@ -227,6 +227,6 @@ struct SftpUploadDir }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SFTPOPERATION_P_H diff --git a/src/plugins/coreplugin/ssh/sftpoutgoingpacket.cpp b/src/libs/utils/ssh/sftpoutgoingpacket.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sftpoutgoingpacket.cpp rename to src/libs/utils/ssh/sftpoutgoingpacket.cpp index 66a06d458ab24447aa6265cb32eb0a7aa55b94d2..21b29b67c487b67e4bc721e1eae1fc741508bd69 100644 --- a/src/plugins/coreplugin/ssh/sftpoutgoingpacket.cpp +++ b/src/libs/utils/ssh/sftpoutgoingpacket.cpp @@ -37,7 +37,7 @@ #include <QtCore/QtEndian> -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -203,4 +203,4 @@ SftpOutgoingPacket &SftpOutgoingPacket::finalize() } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sftpoutgoingpacket_p.h b/src/libs/utils/ssh/sftpoutgoingpacket_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sftpoutgoingpacket_p.h rename to src/libs/utils/ssh/sftpoutgoingpacket_p.h index c88a7298026d224214cefbcdd4414489e68f2cfa..b074da3d0251157df3395941f682f9a1cf3765e5 100644 --- a/src/plugins/coreplugin/ssh/sftpoutgoingpacket_p.h +++ b/src/libs/utils/ssh/sftpoutgoingpacket_p.h @@ -37,7 +37,7 @@ #include "sftppacket_p.h" #include "sftpdefs.h" -namespace Core { +namespace Utils { namespace Internal { class SftpOutgoingPacket : public AbstractSftpPacket @@ -82,6 +82,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SFTPOUTGOINGPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sftppacket.cpp b/src/libs/utils/ssh/sftppacket.cpp similarity index 98% rename from src/plugins/coreplugin/ssh/sftppacket.cpp rename to src/libs/utils/ssh/sftppacket.cpp index c9fe5a581503ba4cb97ebd920f711f95cae43b15..271f96973ae1fc52893818fc0f3b407fa042e0ac 100644 --- a/src/plugins/coreplugin/ssh/sftppacket.cpp +++ b/src/libs/utils/ssh/sftppacket.cpp @@ -35,7 +35,7 @@ #include "sshpacketparser_p.h" -namespace Core { +namespace Utils { namespace Internal { const quint32 AbstractSftpPacket::MaxDataSize = 32000; @@ -55,4 +55,4 @@ quint32 AbstractSftpPacket::requestId() const } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sftppacket_p.h b/src/libs/utils/ssh/sftppacket_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sftppacket_p.h rename to src/libs/utils/ssh/sftppacket_p.h index c6a3af496484f5045570dc629a3cfda8397de8c0..21bd26b68c33756645287e60cc1f5f8f42f5a34b 100644 --- a/src/plugins/coreplugin/ssh/sftppacket_p.h +++ b/src/libs/utils/ssh/sftppacket_p.h @@ -38,7 +38,7 @@ #include <QtCore/QList> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { enum SftpPacketType { @@ -107,6 +107,6 @@ protected: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SFTPPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sshbotanconversions_p.h b/src/libs/utils/ssh/sshbotanconversions_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshbotanconversions_p.h rename to src/libs/utils/ssh/sshbotanconversions_p.h index fa7856f83df7e0652de28e89548882d434435d53..517769d1b2b1291dba814eff12aff3c8df51fdb6 100644 --- a/src/plugins/coreplugin/ssh/sshbotanconversions_p.h +++ b/src/libs/utils/ssh/sshbotanconversions_p.h @@ -39,7 +39,7 @@ #include <botan/rng.h> #include <botan/secmem.h> -namespace Core { +namespace Utils { namespace Internal { inline const Botan::byte *convertByteArray(const QByteArray &a) @@ -96,6 +96,6 @@ inline quint32 botanHMacKeyLen(const QByteArray &rfcAlgoName) } } // namespace Internal -} // namespace Core +} // namespace Utils #endif // BYTEARRAYCONVERSIONS_P_H diff --git a/src/plugins/coreplugin/ssh/sshcapabilities.cpp b/src/libs/utils/ssh/sshcapabilities.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshcapabilities.cpp rename to src/libs/utils/ssh/sshcapabilities.cpp index 589029e8750e267265813699a7153a237ae6a323..389058c134e77e1c375ef85555ce0ba49f373a0f 100644 --- a/src/plugins/coreplugin/ssh/sshcapabilities.cpp +++ b/src/libs/utils/ssh/sshcapabilities.cpp @@ -38,7 +38,7 @@ #include <QtCore/QCoreApplication> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -104,4 +104,4 @@ QByteArray SshCapabilities::findBestMatch(const QList<QByteArray> &myCapabilitie } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshcapabilities_p.h b/src/libs/utils/ssh/sshcapabilities_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshcapabilities_p.h rename to src/libs/utils/ssh/sshcapabilities_p.h index 6a1e1a7b532d24a127fd2ea517de3351681bef10..142ced7aeaf1c3c4c4ab161e6e360637a779aa6e 100644 --- a/src/plugins/coreplugin/ssh/sshcapabilities_p.h +++ b/src/libs/utils/ssh/sshcapabilities_p.h @@ -37,7 +37,7 @@ #include <QtCore/QByteArray> #include <QtCore/QList> -namespace Core { +namespace Utils { namespace Internal { class SshCapabilities @@ -71,6 +71,6 @@ public: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // CAPABILITIES_P_H diff --git a/src/plugins/coreplugin/ssh/sshchannel.cpp b/src/libs/utils/ssh/sshchannel.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshchannel.cpp rename to src/libs/utils/ssh/sshchannel.cpp index 3e8d5d50b398fd4274bbcd20eaa185e6151fdfad..ebd22afe6edb1d68ec5697308b2399b5eb93099b 100644 --- a/src/plugins/coreplugin/ssh/sshchannel.cpp +++ b/src/libs/utils/ssh/sshchannel.cpp @@ -40,7 +40,7 @@ #include <QtCore/QTimer> -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -261,4 +261,4 @@ quint32 AbstractSshChannel::maxDataSize() const } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshchannel_p.h b/src/libs/utils/ssh/sshchannel_p.h similarity index 99% rename from src/plugins/coreplugin/ssh/sshchannel_p.h rename to src/libs/utils/ssh/sshchannel_p.h index 43915046ffeeb0b5eb4496ef05e1affaee519406..9dccc6819ca5616d18d93ff9bba2698d850500c1 100644 --- a/src/plugins/coreplugin/ssh/sshchannel_p.h +++ b/src/libs/utils/ssh/sshchannel_p.h @@ -40,7 +40,7 @@ QT_FORWARD_DECLARE_CLASS(QTimer) -namespace Core { +namespace Utils { namespace Internal { struct SshChannelExitSignal; @@ -124,6 +124,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHCHANNEL_P_H diff --git a/src/plugins/coreplugin/ssh/sshchannelmanager.cpp b/src/libs/utils/ssh/sshchannelmanager.cpp similarity index 96% rename from src/plugins/coreplugin/ssh/sshchannelmanager.cpp rename to src/libs/utils/ssh/sshchannelmanager.cpp index 4362d11542b34bf5ad2f96e91bd7fe871ce04587..a610d6815d2f2380ca5d1a21e002baf31766dc6f 100644 --- a/src/plugins/coreplugin/ssh/sshchannelmanager.cpp +++ b/src/libs/utils/ssh/sshchannelmanager.cpp @@ -42,7 +42,7 @@ #include <QtCore/QList> -namespace Core { +namespace Utils { namespace Internal { SshChannelManager::SshChannelManager(SshSendFacility &sendFacility, @@ -150,14 +150,14 @@ AbstractSshChannel *SshChannelManager::lookupChannel(quint32 channelId, return it == m_channels.end() ? 0 : it.value(); } -Core::SshRemoteProcess::Ptr SshChannelManager::createRemoteProcess(const QByteArray &command) +Utils::SshRemoteProcess::Ptr SshChannelManager::createRemoteProcess(const QByteArray &command) { SshRemoteProcess::Ptr proc(new SshRemoteProcess(command, m_nextLocalChannelId++, m_sendFacility)); insertChannel(proc->d, proc); return proc; } -Core::SftpChannel::Ptr SshChannelManager::createSftpChannel() +Utils::SftpChannel::Ptr SshChannelManager::createSftpChannel() { SftpChannel::Ptr sftp(new SftpChannel(m_nextLocalChannelId++, m_sendFacility)); insertChannel(sftp->d, sftp); @@ -189,4 +189,4 @@ void SshChannelManager::removeChannel(ChannelIterator it) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshchannelmanager_p.h b/src/libs/utils/ssh/sshchannelmanager_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshchannelmanager_p.h rename to src/libs/utils/ssh/sshchannelmanager_p.h index 94b44088c224f7bbf8bd53039b98e3cf9e9163c6..ef7ed5a4faaebbdeb95773b4b35b5ad4b2ccab97 100644 --- a/src/plugins/coreplugin/ssh/sshchannelmanager_p.h +++ b/src/libs/utils/ssh/sshchannelmanager_p.h @@ -38,7 +38,7 @@ #include <QtCore/QObject> #include <QtCore/QSharedPointer> -namespace Core { +namespace Utils { class SftpChannel; class SshRemoteProcess; @@ -92,6 +92,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHCHANNELLAYER_P_H diff --git a/src/plugins/coreplugin/ssh/sshconnection.cpp b/src/libs/utils/ssh/sshconnection.cpp similarity index 97% rename from src/plugins/coreplugin/ssh/sshconnection.cpp rename to src/libs/utils/ssh/sshconnection.cpp index 802c2ae00352dc78266b24dd5140ca7a4fb05af7..f749f1da63bcfdaa1aee8f5dda14754476d91eb8 100644 --- a/src/plugins/coreplugin/ssh/sshconnection.cpp +++ b/src/libs/utils/ssh/sshconnection.cpp @@ -51,7 +51,7 @@ #include <QtNetwork/QNetworkProxy> #include <QtNetwork/QTcpSocket> -namespace Core { +namespace Utils { namespace { const QByteArray ClientId("SSH-2.0-QtCreator\r\n"); @@ -65,8 +65,8 @@ namespace { staticInitMutex.lock(); if (!staticInitializationsDone) { Botan::LibraryInitializer::initialize("thread_safe=true"); - qRegisterMetaType<Core::SshError>("Core::SshError"); - qRegisterMetaType<Core::SftpJobId>("Core::SftpJobId"); + qRegisterMetaType<Utils::SshError>("Utils::SshError"); + qRegisterMetaType<Utils::SftpJobId>("Utils::SftpJobId"); staticInitializationsDone = true; } staticInitMutex.unlock(); @@ -89,12 +89,12 @@ static inline bool equals(const SshConnectionParameters &p1, const SshConnection && p1.timeout == p2.timeout && p1.port == p2.port; } -CORE_EXPORT bool operator==(const SshConnectionParameters &p1, const SshConnectionParameters &p2) +QTCREATOR_UTILS_EXPORT bool operator==(const SshConnectionParameters &p1, const SshConnectionParameters &p2) { return equals(p1, p2); } -CORE_EXPORT bool operator!=(const SshConnectionParameters &p1, const SshConnectionParameters &p2) +QTCREATOR_UTILS_EXPORT bool operator!=(const SshConnectionParameters &p1, const SshConnectionParameters &p2) { return !equals(p1, p2); } @@ -115,8 +115,8 @@ SshConnection::SshConnection() : d(new Internal::SshConnectionPrivate(this)) SIGNAL(dataAvailable(QString)), Qt::QueuedConnection); connect(d, SIGNAL(disconnected()), this, SIGNAL(disconnected()), Qt::QueuedConnection); - connect(d, SIGNAL(error(Core::SshError)), this, - SIGNAL(error(Core::SshError)), Qt::QueuedConnection); + connect(d, SIGNAL(error(Utils::SshError)), this, + SIGNAL(error(Utils::SshError)), Qt::QueuedConnection); } void SshConnection::connectToHost(const SshConnectionParameters &serverInfo) @@ -642,4 +642,4 @@ QSharedPointer<SftpChannel> SshConnectionPrivate::createSftpChannel() const quint64 SshConnectionPrivate::InvalidSeqNr = static_cast<quint64>(-1); } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshconnection.h b/src/libs/utils/ssh/sshconnection.h similarity index 87% rename from src/plugins/coreplugin/ssh/sshconnection.h rename to src/libs/utils/ssh/sshconnection.h index d61517b41b71b40ca579b6d47d8d76c9185001f2..986ff776fe41c735b7befa82426feb61155b8417 100644 --- a/src/plugins/coreplugin/ssh/sshconnection.h +++ b/src/libs/utils/ssh/sshconnection.h @@ -36,14 +36,14 @@ #include "ssherrors.h" -#include <coreplugin/core_global.h> +#include <utils/utils_global.h> #include <QtCore/QByteArray> #include <QtCore/QObject> #include <QtCore/QSharedPointer> #include <QtCore/QString> -namespace Core { +namespace Utils { class SftpChannel; class SshRemoteProcess; @@ -51,7 +51,7 @@ namespace Internal { class SshConnectionPrivate; } // namespace Internal -struct CORE_EXPORT SshConnectionParameters +struct QTCREATOR_UTILS_EXPORT SshConnectionParameters { enum ProxyType { DefaultProxy, NoProxy }; SshConnectionParameters(ProxyType proxyType); @@ -66,15 +66,15 @@ struct CORE_EXPORT SshConnectionParameters ProxyType proxyType; }; -CORE_EXPORT bool operator==(const SshConnectionParameters &p1, const SshConnectionParameters &p2); -CORE_EXPORT bool operator!=(const SshConnectionParameters &p1, const SshConnectionParameters &p2); +QTCREATOR_UTILS_EXPORT bool operator==(const SshConnectionParameters &p1, const SshConnectionParameters &p2); +QTCREATOR_UTILS_EXPORT bool operator!=(const SshConnectionParameters &p1, const SshConnectionParameters &p2); /* * This class provides an SSH connection, implementing protocol version 2.0 * It can spawn channels for remote execution and SFTP operations (version 3). * It operates asynchronously (non-blocking) and is not thread-safe. */ -class CORE_EXPORT SshConnection : public QObject +class QTCREATOR_UTILS_EXPORT SshConnection : public QObject { Q_OBJECT Q_DISABLE_COPY(SshConnection) @@ -99,7 +99,7 @@ signals: void connected(); void disconnected(); void dataAvailable(const QString &message); - void error(Core::SshError); + void error(Utils::SshError); private: SshConnection(); diff --git a/src/plugins/coreplugin/ssh/sshconnection_p.h b/src/libs/utils/ssh/sshconnection_p.h similarity index 97% rename from src/plugins/coreplugin/ssh/sshconnection_p.h rename to src/libs/utils/ssh/sshconnection_p.h index 9a89d99a78d7acae1378d0ecfd81aba110c71df3..629db9a01d5bade4b124b9096b8ecd63dff2f8d9 100644 --- a/src/plugins/coreplugin/ssh/sshconnection_p.h +++ b/src/libs/utils/ssh/sshconnection_p.h @@ -53,7 +53,7 @@ QT_END_NAMESPACE namespace Botan { class Exception; } -namespace Core { +namespace Utils { class SftpChannel; namespace Internal { @@ -76,7 +76,7 @@ enum SshStateInternal { class SshConnectionPrivate : public QObject { Q_OBJECT - friend class Core::SshConnection; + friend class Utils::SshConnection; public: SshConnectionPrivate(SshConnection *conn); ~SshConnectionPrivate(); @@ -94,7 +94,7 @@ signals: void connected(); void disconnected(); void dataAvailable(const QString &message); - void error(Core::SshError); + void error(Utils::SshError); private: Q_SLOT void handleSocketConnected(); @@ -163,6 +163,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHCONNECTION_P_H diff --git a/src/plugins/coreplugin/ssh/sshcryptofacility.cpp b/src/libs/utils/ssh/sshcryptofacility.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshcryptofacility.cpp rename to src/libs/utils/ssh/sshcryptofacility.cpp index 5f6bb69ed37bd635f9f04a3a10187858b456f94d..e2a9495e41c8a481f842d840c162ae6a85041c56 100644 --- a/src/plugins/coreplugin/ssh/sshcryptofacility.cpp +++ b/src/libs/utils/ssh/sshcryptofacility.cpp @@ -58,7 +58,7 @@ using namespace Botan; -namespace Core { +namespace Utils { namespace Internal { SshAbstractCryptoFacility::SshAbstractCryptoFacility() @@ -370,4 +370,4 @@ void SshDecryptionFacility::decrypt(QByteArray &data, quint32 offset, } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshcryptofacility_p.h b/src/libs/utils/ssh/sshcryptofacility_p.h similarity index 99% rename from src/plugins/coreplugin/ssh/sshcryptofacility_p.h rename to src/libs/utils/ssh/sshcryptofacility_p.h index 92bca5d9926b975db6b4b6615bdcec9c5ab19744..494b3681e35f136e9c241953d8e2582cebfe7bd5 100644 --- a/src/plugins/coreplugin/ssh/sshcryptofacility_p.h +++ b/src/libs/utils/ssh/sshcryptofacility_p.h @@ -51,7 +51,7 @@ namespace Botan { class PK_Signing_Key; } -namespace Core { +namespace Utils { namespace Internal { class SshKeyExchange; @@ -153,6 +153,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHABSTRACTCRYPTOFACILITY_P_H diff --git a/src/plugins/coreplugin/ssh/ssherrors.h b/src/libs/utils/ssh/ssherrors.h similarity index 97% rename from src/plugins/coreplugin/ssh/ssherrors.h rename to src/libs/utils/ssh/ssherrors.h index 21d4a42bfb172f211b54654b0d511e14270623db..8fff4dc270bc499f4f7f5b0f289dec13e3d5953e 100644 --- a/src/plugins/coreplugin/ssh/ssherrors.h +++ b/src/libs/utils/ssh/ssherrors.h @@ -34,7 +34,7 @@ #ifndef SSHERRORS_P_H #define SSHERRORS_P_H -namespace Core { +namespace Utils { enum SshError { SshNoError, SshSocketError, SshTimeoutError, SshProtocolError, @@ -42,6 +42,6 @@ enum SshError { SshClosedByServerError, SshInternalError }; -} // namespace Core +} // namespace Utils #endif // SSHERRORS_P_H diff --git a/src/plugins/coreplugin/ssh/sshexception_p.h b/src/libs/utils/ssh/sshexception_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshexception_p.h rename to src/libs/utils/ssh/sshexception_p.h index c634c2f223ba55a6c1f0d608ad06a7940cc5b2f4..7265db362a063904ccced8b132135534195a970f 100644 --- a/src/plugins/coreplugin/ssh/sshexception_p.h +++ b/src/libs/utils/ssh/sshexception_p.h @@ -40,7 +40,7 @@ #include <QtCore/QCoreApplication> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { enum SshErrorCode { @@ -88,6 +88,6 @@ struct SshClientException }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHEXCEPTION_P_H diff --git a/src/plugins/coreplugin/ssh/sshincomingpacket.cpp b/src/libs/utils/ssh/sshincomingpacket.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshincomingpacket.cpp rename to src/libs/utils/ssh/sshincomingpacket.cpp index 2e8bec0d4c01ac8f0688d658cbf280263222a68c..c64ffd4f0e46dca4168dd652fee71d1df3983f2b 100644 --- a/src/plugins/coreplugin/ssh/sshincomingpacket.cpp +++ b/src/libs/utils/ssh/sshincomingpacket.cpp @@ -35,7 +35,7 @@ #include "sshcapabilities_p.h" -namespace Core { +namespace Utils { namespace Internal { const QByteArray SshIncomingPacket::ExitStatusType("exit-status"); @@ -459,4 +459,4 @@ void SshIncomingPacket::calculateLength() const } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshincomingpacket_p.h b/src/libs/utils/ssh/sshincomingpacket_p.h similarity index 99% rename from src/plugins/coreplugin/ssh/sshincomingpacket_p.h rename to src/libs/utils/ssh/sshincomingpacket_p.h index 6c8ce46d84e91377130148ecb4a76bc3a74e358a..d9028d7ec2ff3a68c658a031173357ac372798b0 100644 --- a/src/plugins/coreplugin/ssh/sshincomingpacket_p.h +++ b/src/libs/utils/ssh/sshincomingpacket_p.h @@ -42,7 +42,7 @@ #include <QtCore/QList> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { class SshKeyExchange; @@ -191,6 +191,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHINCOMINGPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sshkeyexchange.cpp b/src/libs/utils/ssh/sshkeyexchange.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshkeyexchange.cpp rename to src/libs/utils/ssh/sshkeyexchange.cpp index bb3e2a28961a6b9b609dd82aaec016beac0054b6..68c850bdd8b28e55a6d2dbb878bfa10ada4ffec5 100644 --- a/src/plugins/coreplugin/ssh/sshkeyexchange.cpp +++ b/src/libs/utils/ssh/sshkeyexchange.cpp @@ -49,7 +49,7 @@ using namespace Botan; -namespace Core { +namespace Utils { namespace Internal { namespace { @@ -198,4 +198,4 @@ void SshKeyExchange::sendNewKeysPacket(const SshIncomingPacket &dhReply, } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshkeyexchange_p.h b/src/libs/utils/ssh/sshkeyexchange_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshkeyexchange_p.h rename to src/libs/utils/ssh/sshkeyexchange_p.h index cdaea098d344bffec1a11d08bd20e4310567f9b9..6a685eb0af4951f52f87ea685ff90643e6f4b9ce 100644 --- a/src/plugins/coreplugin/ssh/sshkeyexchange_p.h +++ b/src/libs/utils/ssh/sshkeyexchange_p.h @@ -41,7 +41,7 @@ namespace Botan { class HashFunction; } -namespace Core { +namespace Utils { namespace Internal { class SshSendFacility; @@ -86,6 +86,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHKEYEXCHANGE_P_H diff --git a/src/plugins/coreplugin/ssh/sshkeygenerator.cpp b/src/libs/utils/ssh/sshkeygenerator.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshkeygenerator.cpp rename to src/libs/utils/ssh/sshkeygenerator.cpp index db2bd602286bb7ee368f2b2e2472232f54139b54..689b6d48b17396b12abeadd1717ab03a04a54153 100644 --- a/src/plugins/coreplugin/ssh/sshkeygenerator.cpp +++ b/src/libs/utils/ssh/sshkeygenerator.cpp @@ -48,7 +48,7 @@ #include <QtCore/QDateTime> -namespace Core { +namespace Utils { using namespace Botan; using namespace Internal; @@ -147,4 +147,4 @@ bool SshKeyGenerator::generateOpenSslKeys(const KeyPtr &key) return true; } -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshkeygenerator.h b/src/libs/utils/ssh/sshkeygenerator.h similarity index 95% rename from src/plugins/coreplugin/ssh/sshkeygenerator.h rename to src/libs/utils/ssh/sshkeygenerator.h index 6416ac74fc4b11d967370231706a7d5e1ed75b20..fa31f3e37d5885a66696775b9060ca2fcff5aeeb 100644 --- a/src/plugins/coreplugin/ssh/sshkeygenerator.h +++ b/src/libs/utils/ssh/sshkeygenerator.h @@ -34,7 +34,7 @@ #ifndef SSHKEYGENERATOR_H #define SSHKEYGENERATOR_H -#include <coreplugin/core_global.h> +#include <utils/utils_global.h> #include <QtCore/QCoreApplication> #include <QtCore/QSharedPointer> @@ -43,9 +43,9 @@ namespace Botan { class Private_Key; } -namespace Core { +namespace Utils { -class CORE_EXPORT SshKeyGenerator +class QTCREATOR_UTILS_EXPORT SshKeyGenerator { Q_DECLARE_TR_FUNCTIONS(SshKeyGenerator) public: @@ -74,6 +74,6 @@ private: PrivateKeyFormat m_format; }; -} // namespace Core +} // namespace Utils #endif // SSHKEYGENERATOR_H diff --git a/src/plugins/coreplugin/ssh/sshoutgoingpacket.cpp b/src/libs/utils/ssh/sshoutgoingpacket.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshoutgoingpacket.cpp rename to src/libs/utils/ssh/sshoutgoingpacket.cpp index c99db71acad7996d08e76ae3c5715a8fe5f904c3..445aa75ae2a07f251cf5c86c4425305c00887232 100644 --- a/src/plugins/coreplugin/ssh/sshoutgoingpacket.cpp +++ b/src/libs/utils/ssh/sshoutgoingpacket.cpp @@ -38,7 +38,7 @@ #include <QtCore/QtEndian> -namespace Core { +namespace Utils { namespace Internal { SshOutgoingPacket::SshOutgoingPacket(const SshEncryptionFacility &encrypter, @@ -295,4 +295,4 @@ QByteArray SshOutgoingPacket::encodeNameList(const QList<QByteArray> &list) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshoutgoingpacket_p.h b/src/libs/utils/ssh/sshoutgoingpacket_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshoutgoingpacket_p.h rename to src/libs/utils/ssh/sshoutgoingpacket_p.h index da7f6fcc03cb4f01729ae36a13c4bb04f3104718..22adf6d2e7c3300eacdcfc0262ec2ce086d53e13 100644 --- a/src/plugins/coreplugin/ssh/sshoutgoingpacket_p.h +++ b/src/libs/utils/ssh/sshoutgoingpacket_p.h @@ -36,7 +36,7 @@ #include "sshpacket_p.h" -namespace Core { +namespace Utils { namespace Internal { class SshEncryptionFacility; @@ -99,6 +99,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHOUTGOINGPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sshpacket.cpp b/src/libs/utils/ssh/sshpacket.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshpacket.cpp rename to src/libs/utils/ssh/sshpacket.cpp index 4ddba455b473cdd933602d698b7b973bbe4b91bb..0ec644786ec0cd0f9c20326031d6ef1f36059318 100644 --- a/src/plugins/coreplugin/ssh/sshpacket.cpp +++ b/src/libs/utils/ssh/sshpacket.cpp @@ -42,7 +42,7 @@ #include <cctype> -namespace Core { +namespace Utils { namespace Internal { const quint32 AbstractSshPacket::PaddingLengthOffset = 4; @@ -168,4 +168,4 @@ void AbstractSshPacket::setLengthField(QByteArray &data) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshpacket_p.h b/src/libs/utils/ssh/sshpacket_p.h similarity index 99% rename from src/plugins/coreplugin/ssh/sshpacket_p.h rename to src/libs/utils/ssh/sshpacket_p.h index 1f66797a9ac5c15be3ef83fa95f1f9f8a9bd8880..e2641ea5e45effa185f1b0bb5519fc2596a700cd 100644 --- a/src/plugins/coreplugin/ssh/sshpacket_p.h +++ b/src/libs/utils/ssh/sshpacket_p.h @@ -42,7 +42,7 @@ #include <botan/bigint.h> -namespace Core { +namespace Utils { namespace Internal { enum SshPacketType { @@ -141,6 +141,6 @@ protected: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHPACKET_P_H diff --git a/src/plugins/coreplugin/ssh/sshpacketparser.cpp b/src/libs/utils/ssh/sshpacketparser.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshpacketparser.cpp rename to src/libs/utils/ssh/sshpacketparser.cpp index 26f8ed4d59a1414ab2bc8c4df7b6f6fa9be5869e..f83c395de3576332d87a0ca4198bee402e6cd1f8 100644 --- a/src/plugins/coreplugin/ssh/sshpacketparser.cpp +++ b/src/libs/utils/ssh/sshpacketparser.cpp @@ -35,7 +35,7 @@ #include <cctype> -namespace Core { +namespace Utils { namespace Internal { namespace { quint32 size(const QByteArray &data) { return data.size(); } } @@ -154,4 +154,4 @@ Botan::BigInt SshPacketParser::asBigInt(const QByteArray &data, quint32 *offset) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshpacketparser_p.h b/src/libs/utils/ssh/sshpacketparser_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshpacketparser_p.h rename to src/libs/utils/ssh/sshpacketparser_p.h index 061fd0389f6d79737e9c822e10a771e0e6dd6d80..0c87ac77c8349314e7629fe4b992f9b0906ddc36 100644 --- a/src/plugins/coreplugin/ssh/sshpacketparser_p.h +++ b/src/libs/utils/ssh/sshpacketparser_p.h @@ -40,7 +40,7 @@ #include <QtCore/QList> #include <QtCore/QString> -namespace Core { +namespace Utils { namespace Internal { struct SshNameList @@ -80,6 +80,6 @@ public: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHPACKETPARSER_P_H diff --git a/src/plugins/coreplugin/ssh/sshremoteprocess.cpp b/src/libs/utils/ssh/sshremoteprocess.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshremoteprocess.cpp rename to src/libs/utils/ssh/sshremoteprocess.cpp index 97a4c9ebe9ec73673e63a57825099a9da0a4d1cd..b6d71167a398ccaa86e4853fdd0a82eb262aeb1b 100644 --- a/src/plugins/coreplugin/ssh/sshremoteprocess.cpp +++ b/src/libs/utils/ssh/sshremoteprocess.cpp @@ -41,7 +41,7 @@ #include <QtCore/QTimer> -namespace Core { +namespace Utils { const QByteArray SshRemoteProcess::AbrtSignal("ABRT"); const QByteArray SshRemoteProcess::AlrmSignal("ALRM"); @@ -234,4 +234,4 @@ void SshRemoteProcessPrivate::handleExitSignal(const SshChannelExitSignal &signa } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshremoteprocess.h b/src/libs/utils/ssh/sshremoteprocess.h similarity index 96% rename from src/plugins/coreplugin/ssh/sshremoteprocess.h rename to src/libs/utils/ssh/sshremoteprocess.h index 3250da56ae14c6e1615262dfaf7bd9ec7724d173..d0b996cc540e2ff40749f61e804c8dc730d91cbd 100644 --- a/src/plugins/coreplugin/ssh/sshremoteprocess.h +++ b/src/libs/utils/ssh/sshremoteprocess.h @@ -34,7 +34,7 @@ #ifndef SSHREMOTECOMMAND_H #define SSHREMOTECOMMAND_H -#include <coreplugin/core_global.h> +#include <utils/utils_global.h> #include <QtCore/QObject> #include <QtCore/QSharedPointer> @@ -43,7 +43,7 @@ QT_BEGIN_NAMESPACE class QByteArray; QT_END_NAMESPACE -namespace Core { +namespace Utils { namespace Internal { class SshChannelManager; class SshRemoteProcessPrivate; @@ -63,7 +63,7 @@ class SshSendFacility; * Note that the process does not have a terminal, so you can't use it * for applications that require one. */ -class CORE_EXPORT SshRemoteProcess : public QObject +class QTCREATOR_UTILS_EXPORT SshRemoteProcess : public QObject { Q_OBJECT Q_DISABLE_COPY(SshRemoteProcess) @@ -129,6 +129,6 @@ private: Internal::SshRemoteProcessPrivate *d; }; -} // namespace Core +} // namespace Utils #endif // SSHREMOTECOMMAND_H diff --git a/src/plugins/coreplugin/ssh/sshremoteprocess_p.h b/src/libs/utils/ssh/sshremoteprocess_p.h similarity index 97% rename from src/plugins/coreplugin/ssh/sshremoteprocess_p.h rename to src/libs/utils/ssh/sshremoteprocess_p.h index 6d0af6e6a91c3b65a21e810028955677c7706d4e..d667bde2f04b1a156ac27f1922a574006fb1fb2e 100644 --- a/src/plugins/coreplugin/ssh/sshremoteprocess_p.h +++ b/src/libs/utils/ssh/sshremoteprocess_p.h @@ -39,7 +39,7 @@ #include <QtCore/QList> #include <QtCore/QPair> -namespace Core { +namespace Utils { class SshRemoteProcess; namespace Internal { @@ -48,7 +48,7 @@ class SshSendFacility; class SshRemoteProcessPrivate : public AbstractSshChannel { Q_OBJECT - friend class Core::SshRemoteProcess; + friend class Utils::SshRemoteProcess; public: enum ProcessState { NotYetStarted, ExecRequested, StartFailed,Running, Exited @@ -93,6 +93,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHREMOTEPROCESS_P_H diff --git a/src/plugins/coreplugin/ssh/sshremoteprocessrunner.cpp b/src/libs/utils/ssh/sshremoteprocessrunner.cpp similarity index 92% rename from src/plugins/coreplugin/ssh/sshremoteprocessrunner.cpp rename to src/libs/utils/ssh/sshremoteprocessrunner.cpp index f8ded6a2c16a1a408683fee8ba80bec09d05fde5..fcff1692f0a543348bf679eca0a29e9309b5459a 100644 --- a/src/plugins/coreplugin/ssh/sshremoteprocessrunner.cpp +++ b/src/libs/utils/ssh/sshremoteprocessrunner.cpp @@ -2,7 +2,7 @@ #define ASSERT_STATE(states) assertState(states, Q_FUNC_INFO) -namespace Core { +namespace Utils { class SshRemoteProcessRunnerPrivate : public QObject { @@ -19,7 +19,7 @@ public: SshRemoteProcess::Ptr m_process; signals: - void connectionError(Core::SshError); + void connectionError(Utils::SshError); void processStarted(); void processOutputAvailable(const QByteArray &output); void processErrorOutputAvailable(const QByteArray &output); @@ -27,7 +27,7 @@ signals: private slots: void handleConnected(); - void handleConnectionError(Core::SshError error); + void handleConnectionError(Utils::SshError error); void handleDisconnected(); void handleProcessStarted(); void handleProcessFinished(int exitStatus); @@ -69,8 +69,8 @@ void SshRemoteProcessRunnerPrivate::run(const QByteArray &command) setState(Connecting); m_command = command; - connect(m_connection.data(), SIGNAL(error(Core::SshError)), - SLOT(handleConnectionError(Core::SshError))); + connect(m_connection.data(), SIGNAL(error(Utils::SshError)), + SLOT(handleConnectionError(Utils::SshError))); connect(m_connection.data(), SIGNAL(disconnected()), SLOT(handleDisconnected())); if (m_connection->state() == SshConnection::Connected) { @@ -98,7 +98,7 @@ void SshRemoteProcessRunnerPrivate::handleConnected() m_process->start(); } -void SshRemoteProcessRunnerPrivate::handleConnectionError(Core::SshError error) +void SshRemoteProcessRunnerPrivate::handleConnectionError(Utils::SshError error) { handleDisconnected(); emit connectionError(error); @@ -185,8 +185,8 @@ SshRemoteProcessRunner::SshRemoteProcessRunner(const SshConnection::Ptr &connect void SshRemoteProcessRunner::init() { - connect(d, SIGNAL(connectionError(Core::SshError)), - SIGNAL(connectionError(Core::SshError))); + connect(d, SIGNAL(connectionError(Utils::SshError)), + SIGNAL(connectionError(Utils::SshError))); connect(d, SIGNAL(processStarted()), SIGNAL(processStarted())); connect(d, SIGNAL(processClosed(int)), SIGNAL(processClosed(int))); connect(d, SIGNAL(processOutputAvailable(QByteArray)), @@ -204,7 +204,7 @@ QByteArray SshRemoteProcessRunner::command() const { return d->command(); } SshConnection::Ptr SshRemoteProcessRunner::connection() const { return d->m_connection; } SshRemoteProcess::Ptr SshRemoteProcessRunner::process() const { return d->m_process; } -} // namespace Core +} // namespace Utils #include "sshremoteprocessrunner.moc" diff --git a/src/plugins/coreplugin/ssh/sshremoteprocessrunner.h b/src/libs/utils/ssh/sshremoteprocessrunner.h similarity index 88% rename from src/plugins/coreplugin/ssh/sshremoteprocessrunner.h rename to src/libs/utils/ssh/sshremoteprocessrunner.h index c55b08aa1c3547026f7a15f66eb78fa3040e1f9f..a8eff8b5137d6734c1b67dacb8647a5f24b27a05 100644 --- a/src/plugins/coreplugin/ssh/sshremoteprocessrunner.h +++ b/src/libs/utils/ssh/sshremoteprocessrunner.h @@ -4,11 +4,11 @@ #include "sshconnection.h" #include "sshremoteprocess.h" -namespace Core { +namespace Utils { class SshRemoteProcessRunnerPrivate; // Convenience class for running a remote process over an SSH connection. -class CORE_EXPORT SshRemoteProcessRunner : public QObject +class QTCREATOR_UTILS_EXPORT SshRemoteProcessRunner : public QObject { Q_OBJECT Q_DISABLE_COPY(SshRemoteProcessRunner) @@ -25,7 +25,7 @@ public: SshRemoteProcess::Ptr process() const; signals: - void connectionError(Core::SshError); + void connectionError(Utils::SshError); void processStarted(); void processOutputAvailable(const QByteArray &output); void processErrorOutputAvailable(const QByteArray &output); @@ -39,6 +39,6 @@ private: SshRemoteProcessRunnerPrivate *d; }; -} // namespace Core +} // namespace Utils #endif // SSHREMOTEPROCESSRUNNER_H diff --git a/src/plugins/coreplugin/ssh/sshsendfacility.cpp b/src/libs/utils/ssh/sshsendfacility.cpp similarity index 99% rename from src/plugins/coreplugin/ssh/sshsendfacility.cpp rename to src/libs/utils/ssh/sshsendfacility.cpp index 150118fd8c5a73cd12f8e07325404623975384af..95116aaf6f436cb9aba82586c6a894d6d7e2a79d 100644 --- a/src/plugins/coreplugin/ssh/sshsendfacility.cpp +++ b/src/libs/utils/ssh/sshsendfacility.cpp @@ -38,7 +38,7 @@ #include <QtNetwork/QTcpSocket> -namespace Core { +namespace Utils { namespace Internal { SshSendFacility::SshSendFacility(QTcpSocket *socket) @@ -207,4 +207,4 @@ void SshSendFacility::sendChannelClosePacket(quint32 remoteChannel) } } // namespace Internal -} // namespace Core +} // namespace Utils diff --git a/src/plugins/coreplugin/ssh/sshsendfacility_p.h b/src/libs/utils/ssh/sshsendfacility_p.h similarity index 98% rename from src/plugins/coreplugin/ssh/sshsendfacility_p.h rename to src/libs/utils/ssh/sshsendfacility_p.h index 366413917b3ee93092ae6c8b51c7b183a191d6cf..9cd7cd6ad1e5da52383e76e8355dc97b786d7411 100644 --- a/src/plugins/coreplugin/ssh/sshsendfacility_p.h +++ b/src/libs/utils/ssh/sshsendfacility_p.h @@ -42,7 +42,7 @@ class QTcpSocket; QT_END_NAMESPACE -namespace Core { +namespace Utils { namespace Internal { class SshKeyExchange; @@ -92,6 +92,6 @@ private: }; } // namespace Internal -} // namespace Core +} // namespace Utils #endif // SSHCONNECTIONOUTSTATE_P_H diff --git a/src/libs/utils/utils-lib.pri b/src/libs/utils/utils-lib.pri index 7d83452b78847246f8525bedee3d44d111c28900..f6711bee361f817f6b2c6bd377a86efff7cfd573 100644 --- a/src/libs/utils/utils-lib.pri +++ b/src/libs/utils/utils-lib.pri @@ -55,7 +55,27 @@ SOURCES += $$PWD/environment.cpp \ $$PWD/buildablehelperlibrary.cpp \ $$PWD/annotateditemdelegate.cpp \ $$PWD/fileinprojectfinder.cpp \ - $$PWD/ipaddresslineedit.cpp + $$PWD/ipaddresslineedit.cpp \ + $$PWD/ssh/sshsendfacility.cpp \ + $$PWD/ssh/sshremoteprocess.cpp \ + $$PWD/ssh/sshpacketparser.cpp \ + $$PWD/ssh/sshpacket.cpp \ + $$PWD/ssh/sshoutgoingpacket.cpp \ + $$PWD/ssh/sshkeygenerator.cpp \ + $$PWD/ssh/sshkeyexchange.cpp \ + $$PWD/ssh/sshincomingpacket.cpp \ + $$PWD/ssh/sshcryptofacility.cpp \ + $$PWD/ssh/sshconnection.cpp \ + $$PWD/ssh/sshchannelmanager.cpp \ + $$PWD/ssh/sshchannel.cpp \ + $$PWD/ssh/sshcapabilities.cpp \ + $$PWD/ssh/sftppacket.cpp \ + $$PWD/ssh/sftpoutgoingpacket.cpp \ + $$PWD/ssh/sftpoperation.cpp \ + $$PWD/ssh/sftpincomingpacket.cpp \ + $$PWD/ssh/sftpdefs.cpp \ + $$PWD/ssh/sftpchannel.cpp \ + $$PWD/ssh/sshremoteprocessrunner.cpp win32 { SOURCES += $$PWD/abstractprocess_win.cpp \ @@ -121,7 +141,33 @@ HEADERS += $$PWD/environment.h \ $$PWD/buildablehelperlibrary.h \ $$PWD/annotateditemdelegate.h \ $$PWD/fileinprojectfinder.h \ - $$PWD/ipaddresslineedit.h + $$PWD/ipaddresslineedit.h \ + $$PWD/ssh/sshsendfacility_p.h \ + $$PWD/ssh/sshremoteprocess.h \ + $$PWD/ssh/sshremoteprocess_p.h \ + $$PWD/ssh/sshpacketparser_p.h \ + $$PWD/ssh/sshpacket_p.h \ + $$PWD/ssh/sshoutgoingpacket_p.h \ + $$PWD/ssh/sshkeygenerator.h \ + $$PWD/ssh/sshkeyexchange_p.h \ + $$PWD/ssh/sshincomingpacket_p.h \ + $$PWD/ssh/sshexception_p.h \ + $$PWD/ssh/ssherrors.h \ + $$PWD/ssh/sshcryptofacility_p.h \ + $$PWD/ssh/sshconnection.h \ + $$PWD/ssh/sshconnection_p.h \ + $$PWD/ssh/sshchannelmanager_p.h \ + $$PWD/ssh/sshchannel_p.h \ + $$PWD/ssh/sshcapabilities_p.h \ + $$PWD/ssh/sshbotanconversions_p.h \ + $$PWD/ssh/sftppacket_p.h \ + $$PWD/ssh/sftpoutgoingpacket_p.h \ + $$PWD/ssh/sftpoperation_p.h \ + $$PWD/ssh/sftpincomingpacket_p.h \ + $$PWD/ssh/sftpdefs.h \ + $$PWD/ssh/sftpchannel.h \ + $$PWD/ssh/sftpchannel_p.h \ + $$PWD/ssh/sshremoteprocessrunner.h FORMS += $$PWD/filewizardpage.ui \ $$PWD/projectintropage.ui \ diff --git a/src/libs/utils/utils.pro b/src/libs/utils/utils.pro index 7a3d40146a708da797ea69704c6c860fc9c5e4a6..dbf97987c288c52bcc28cd926f42fbebdabe9bb7 100644 --- a/src/libs/utils/utils.pro +++ b/src/libs/utils/utils.pro @@ -5,6 +5,7 @@ QT += gui \ CONFIG += dll include($$PWD/../../qtcreatorlibrary.pri) +include($$PWD/../3rdparty/botan/botan.pri) include(utils-lib.pri) diff --git a/src/plugins/coreplugin/coreplugin.pro b/src/plugins/coreplugin/coreplugin.pro index dd416a7cc0edc88f1e072db27a7b9b2b26756e32..b8db79dbf4b37ed1e1eefb6edc19328cd151155b 100644 --- a/src/plugins/coreplugin/coreplugin.pro +++ b/src/plugins/coreplugin/coreplugin.pro @@ -84,26 +84,6 @@ SOURCES += mainwindow.cpp \ designmode.cpp \ editortoolbar.cpp \ helpmanager.cpp \ - ssh/sshsendfacility.cpp \ - ssh/sshremoteprocess.cpp \ - ssh/sshpacketparser.cpp \ - ssh/sshpacket.cpp \ - ssh/sshoutgoingpacket.cpp \ - ssh/sshkeygenerator.cpp \ - ssh/sshkeyexchange.cpp \ - ssh/sshincomingpacket.cpp \ - ssh/sshcryptofacility.cpp \ - ssh/sshconnection.cpp \ - ssh/sshchannelmanager.cpp \ - ssh/sshchannel.cpp \ - ssh/sshcapabilities.cpp \ - ssh/sftppacket.cpp \ - ssh/sftpoutgoingpacket.cpp \ - ssh/sftpoperation.cpp \ - ssh/sftpincomingpacket.cpp \ - ssh/sftpdefs.cpp \ - ssh/sftpchannel.cpp \ - ssh/sshremoteprocessrunner.cpp \ outputpanemanager.cpp \ navigationsubwidget.cpp \ sidebarwidget.cpp \ @@ -189,32 +169,6 @@ HEADERS += mainwindow.h \ designmode.h \ editortoolbar.h \ helpmanager.h \ - ssh/sshsendfacility_p.h \ - ssh/sshremoteprocess.h \ - ssh/sshremoteprocess_p.h \ - ssh/sshpacketparser_p.h \ - ssh/sshpacket_p.h \ - ssh/sshoutgoingpacket_p.h \ - ssh/sshkeygenerator.h \ - ssh/sshkeyexchange_p.h \ - ssh/sshincomingpacket_p.h \ - ssh/sshexception_p.h \ - ssh/ssherrors.h \ - ssh/sshcryptofacility_p.h \ - ssh/sshconnection.h \ - ssh/sshconnection_p.h \ - ssh/sshchannelmanager_p.h \ - ssh/sshchannel_p.h \ - ssh/sshcapabilities_p.h \ - ssh/sshbotanconversions_p.h \ - ssh/sftppacket_p.h \ - ssh/sftpoutgoingpacket_p.h \ - ssh/sftpoperation_p.h \ - ssh/sftpincomingpacket_p.h \ - ssh/sftpdefs.h \ - ssh/sftpchannel.h \ - ssh/sftpchannel_p.h \ - ssh/sshremoteprocessrunner.h \ outputpanemanager.h \ navigationsubwidget.h \ sidebarwidget.h \ diff --git a/src/plugins/debugger/debuggerplugin.cpp b/src/plugins/debugger/debuggerplugin.cpp index 263fcd3f98eba129a609f28718f99bdb9430acc1..3d627ad608c7131b79cb92824acccf64270a4c50 100644 --- a/src/plugins/debugger/debuggerplugin.cpp +++ b/src/plugins/debugger/debuggerplugin.cpp @@ -1715,9 +1715,9 @@ void DebuggerPluginPrivate::startRemoteEngine() sp.connParams.pwd = dlg.password(); sp.connParams.timeout = 5; - sp.connParams.authType = SshConnectionParameters::AuthByPwd; + sp.connParams.authType = Utils::SshConnectionParameters::AuthByPwd; sp.connParams.port = 22; - sp.connParams.proxyType = SshConnectionParameters::NoProxy; + sp.connParams.proxyType = Utils::SshConnectionParameters::NoProxy; sp.executable = dlg.inferiorPath(); sp.serverStartScript = dlg.enginePath(); diff --git a/src/plugins/debugger/debuggerstartparameters.h b/src/plugins/debugger/debuggerstartparameters.h index 02fd27d8e3a82736d5c5edd43a7d4f280e8b3688..2fe82d4bc0d138a3e734b9f92d3fa6194d6e338a 100644 --- a/src/plugins/debugger/debuggerstartparameters.h +++ b/src/plugins/debugger/debuggerstartparameters.h @@ -37,7 +37,7 @@ #include "debugger_global.h" #include "debuggerconstants.h" -#include <coreplugin/ssh/sshconnection.h> +#include <utils/ssh/sshconnection.h> #include <utils/environment.h> #include <projectexplorer/toolchaintype.h> @@ -69,7 +69,7 @@ public: qmlServerAddress(QLatin1String("127.0.0.1")), qmlServerPort(0), useServerStartScript(false), - connParams(Core::SshConnectionParameters::NoProxy), + connParams(Utils::SshConnectionParameters::NoProxy), toolChainType(ProjectExplorer::ToolChain_UNKNOWN), startMode(NoStartMode), executableUid(0), @@ -114,7 +114,7 @@ public: QByteArray remoteSourcesDir; QString remoteMountPoint; QString localMountDir; - Core::SshConnectionParameters connParams; + Utils::SshConnectionParameters connParams; QString debuggerCommand; ProjectExplorer::ToolChainType toolChainType; diff --git a/src/plugins/debugger/gdb/remotegdbprocess.cpp b/src/plugins/debugger/gdb/remotegdbprocess.cpp index 60b5ec6bd5fb6c7032b723d5f1194b8eba50ba99..fe034052ffaa8f1a5e917e26432567f1921cc0e5 100644 --- a/src/plugins/debugger/gdb/remotegdbprocess.cpp +++ b/src/plugins/debugger/gdb/remotegdbprocess.cpp @@ -47,7 +47,7 @@ using namespace Core; namespace Debugger { namespace Internal { -RemoteGdbProcess::RemoteGdbProcess(const Core::SshConnectionParameters &connParams, +RemoteGdbProcess::RemoteGdbProcess(const Utils::SshConnectionParameters &connParams, RemotePlainGdbAdapter *adapter, QObject *parent) : AbstractGdbProcess(parent), m_connParams(connParams), m_state(Inactive), m_adapter(adapter) @@ -91,9 +91,9 @@ void RemoteGdbProcess::realStart(const QString &cmd, const QStringList &args, m_gdbOutput.clear(); m_errorOutput.clear(); m_inputToSend.clear(); - m_conn = SshConnection::create(); + m_conn = Utils::SshConnection::create(); connect(m_conn.data(), SIGNAL(connected()), this, SLOT(handleConnected())); - connect(m_conn.data(), SIGNAL(error(Core::SshError)), this, + connect(m_conn.data(), SIGNAL(error(Utils::SshError)), this, SLOT(handleConnectionError())); m_conn->connectToHost(m_connParams); } @@ -125,7 +125,7 @@ void RemoteGdbProcess::handleFifoCreationFinished(int exitStatus) return; QTC_ASSERT(m_state == CreatingFifo, return); - if (exitStatus != SshRemoteProcess::ExitedNormally) { + if (exitStatus != Utils::SshRemoteProcess::ExitedNormally) { emitErrorExit(tr("Could not create FIFO.")); } else { setState(StartingFifoReader); @@ -167,7 +167,7 @@ void RemoteGdbProcess::handleAppOutputReaderStarted() void RemoteGdbProcess::handleAppOutputReaderFinished(int exitStatus) { - if (exitStatus != SshRemoteProcess::ExitedNormally) + if (exitStatus != Utils::SshRemoteProcess::ExitedNormally) emitErrorExit(tr("Application output reader unexpectedly finished.")); } @@ -187,15 +187,15 @@ void RemoteGdbProcess::handleGdbFinished(int exitStatus) QTC_ASSERT(m_state == RunningGdb, return); switch (exitStatus) { - case SshRemoteProcess::FailedToStart: + case Utils::SshRemoteProcess::FailedToStart: m_error = tr("Remote gdb failed to start."); setState(Inactive); emit startFailed(); break; - case SshRemoteProcess::KilledBySignal: + case Utils::SshRemoteProcess::KilledBySignal: emitErrorExit(tr("Remote gdb crashed.")); break; - case SshRemoteProcess::ExitedNormally: + case Utils::SshRemoteProcess::ExitedNormally: const int exitCode = m_gdbProc->exitCode(); setState(Inactive); emit finished(exitCode, QProcess::NormalExit); @@ -224,7 +224,7 @@ qint64 RemoteGdbProcess::write(const QByteArray &data) void RemoteGdbProcess::kill() { if (m_state == RunningGdb) { - SshRemoteProcess::Ptr killProc + Utils::SshRemoteProcess::Ptr killProc = m_conn->createRemoteProcess("pkill -SIGKILL -x gdb"); killProc->start(); } else { @@ -236,7 +236,7 @@ void RemoteGdbProcess::interruptInferior() { QTC_ASSERT(m_state == RunningGdb, return); - SshRemoteProcess::Ptr intProc + Utils::SshRemoteProcess::Ptr intProc = m_conn->createRemoteProcess("pkill -x -SIGINT gdb"); intProc->start(); } @@ -375,15 +375,15 @@ void RemoteGdbProcess::setState(State newState) if (m_state == Inactive) { if (m_gdbProc) { disconnect(m_gdbProc.data(), 0, this, 0); - m_gdbProc = SshRemoteProcess::Ptr(); + m_gdbProc = Utils::SshRemoteProcess::Ptr(); } if (m_appOutputReader) { disconnect(m_appOutputReader.data(), 0, this, 0); - m_appOutputReader = SshRemoteProcess::Ptr(); + m_appOutputReader = Utils::SshRemoteProcess::Ptr(); } if (m_fifoCreator) { disconnect(m_fifoCreator.data(), 0, this, 0); - m_fifoCreator = SshRemoteProcess::Ptr(); + m_fifoCreator = Utils::SshRemoteProcess::Ptr(); } disconnect(m_conn.data(), 0, this, 0); m_conn->disconnectFromHost(); diff --git a/src/plugins/debugger/gdb/remotegdbprocess.h b/src/plugins/debugger/gdb/remotegdbprocess.h index c1152a1e8da599f8934404a98acc352d5333a59c..adb1aef412f8715c1ff0add054e5605342ba0334 100644 --- a/src/plugins/debugger/gdb/remotegdbprocess.h +++ b/src/plugins/debugger/gdb/remotegdbprocess.h @@ -36,8 +36,8 @@ #include "abstractgdbprocess.h" -#include <coreplugin/ssh/sshconnection.h> -#include <coreplugin/ssh/sshremoteprocess.h> +#include <utils/ssh/sshconnection.h> +#include <utils/ssh/sshremoteprocess.h> #include <QtCore/QByteArray> #include <QtCore/QQueue> @@ -51,7 +51,7 @@ class RemoteGdbProcess : public AbstractGdbProcess { Q_OBJECT public: - RemoteGdbProcess(const Core::SshConnectionParameters &server, + RemoteGdbProcess(const Utils::SshConnectionParameters &server, RemotePlainGdbAdapter *adapter, QObject *parent = 0); virtual QByteArray readAllStandardOutput(); @@ -106,11 +106,11 @@ private: void emitErrorExit(const QString &error); void setState(State newState); - Core::SshConnectionParameters m_connParams; - Core::SshConnection::Ptr m_conn; - Core::SshRemoteProcess::Ptr m_gdbProc; - Core::SshRemoteProcess::Ptr m_appOutputReader; - Core::SshRemoteProcess::Ptr m_fifoCreator; + Utils::SshConnectionParameters m_connParams; + Utils::SshConnection::Ptr m_conn; + Utils::SshRemoteProcess::Ptr m_gdbProc; + Utils::SshRemoteProcess::Ptr m_appOutputReader; + Utils::SshRemoteProcess::Ptr m_fifoCreator; QByteArray m_gdbOutput; QByteArray m_errorOutput; QString m_command; diff --git a/src/plugins/debugger/lldb/lldbenginehost.cpp b/src/plugins/debugger/lldb/lldbenginehost.cpp index fa4f3fb064b5d77c7bcaa3b2ee6ff82846235489..03af9d30a56b581a8c60324f754b936b0cb4d289 100644 --- a/src/plugins/debugger/lldb/lldbenginehost.cpp +++ b/src/plugins/debugger/lldb/lldbenginehost.cpp @@ -65,7 +65,7 @@ namespace Debugger { namespace Internal { -SshIODevice::SshIODevice(Core::SshRemoteProcessRunner::Ptr r) +SshIODevice::SshIODevice(Utils::SshRemoteProcessRunner::Ptr r) : runner(r) , buckethead(0) { @@ -147,10 +147,10 @@ LldbEngineHost::LldbEngineHost(const DebuggerStartParameters &startParameters) if (startParameters.startMode == StartRemoteEngine) { m_guestProcess = 0; - Core::SshRemoteProcessRunner::Ptr runner = - Core::SshRemoteProcessRunner::create(startParameters.connParams); - connect (runner.data(), SIGNAL(connectionError(Core::SshError)), - this, SLOT(sshConnectionError(Core::SshError))); + Utils::SshRemoteProcessRunner::Ptr runner = + Utils::SshRemoteProcessRunner::create(startParameters.connParams); + connect (runner.data(), SIGNAL(connectionError(Utils::SshError)), + this, SLOT(sshConnectionError(Utils::SshError))); runner->run(startParameters.serverStartScript.toUtf8()); setGuestDevice(new SshIODevice(runner)); } else { @@ -210,7 +210,7 @@ void LldbEngineHost::nuke() m_guestProcess->kill(); notifyEngineSpontaneousShutdown(); } -void LldbEngineHost::sshConnectionError(Core::SshError e) +void LldbEngineHost::sshConnectionError(Utils::SshError e) { showStatusMessage(tr("ssh connection error: %1").arg(e)); } diff --git a/src/plugins/debugger/lldb/lldbenginehost.h b/src/plugins/debugger/lldb/lldbenginehost.h index 3b81b2dd60c600b3fdf4f0fb336a0b0323b0cd87..5adced6d9381bb970be1957cb44927e981e02d51 100644 --- a/src/plugins/debugger/lldb/lldbenginehost.h +++ b/src/plugins/debugger/lldb/lldbenginehost.h @@ -35,10 +35,10 @@ #define DEBUGGER_LLDBENGINE_HOST_H #include "ipcenginehost.h" -#include <coreplugin/ssh/ssherrors.h> -#include <coreplugin/ssh/sshconnection.h> -#include <coreplugin/ssh/sshremoteprocess.h> -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/ssherrors.h> +#include <utils/ssh/sshconnection.h> +#include <utils/ssh/sshremoteprocess.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtCore/QProcess> #include <QtCore/QQueue> @@ -50,7 +50,7 @@ class SshIODevice : public QIODevice { Q_OBJECT public: - SshIODevice(Core::SshRemoteProcessRunner::Ptr r); + SshIODevice(Utils::SshRemoteProcessRunner::Ptr r); virtual qint64 bytesAvailable () const; virtual qint64 writeData (const char * data, qint64 maxSize); virtual qint64 readData (char * data, qint64 maxSize); @@ -59,8 +59,8 @@ private slots: void outputAvailable(const QByteArray &output); void errorOutputAvailable(const QByteArray &output); private: - Core::SshRemoteProcessRunner::Ptr runner; - Core::SshRemoteProcess::Ptr proc; + Utils::SshRemoteProcessRunner::Ptr runner; + Utils::SshRemoteProcess::Ptr proc; int buckethead; QQueue<QByteArray> buckets; QByteArray startupbuffer; @@ -76,11 +76,11 @@ public: private: QProcess *m_guestProcess; - Core::SshRemoteProcessRunner::Ptr m_ssh; + Utils::SshRemoteProcessRunner::Ptr m_ssh; protected: void nuke(); private slots: - void sshConnectionError(Core::SshError); + void sshConnectionError(Utils::SshError); void finished(int, QProcess::ExitStatus); void stderrReady(); }; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.cpp index 01dd025f71e56efe4b812f322991833ae37b5124..a072e536a99c563f9ee0e886fa3c93ae323cdca7 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.cpp @@ -39,12 +39,12 @@ #include "maemoglobal.h" #include "maemousedportsgatherer.h" -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtGui/QPalette> #include <QtGui/QPushButton> -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -87,7 +87,7 @@ void MaemoConfigTestDialog::startConfigTest() m_ui->testResultEdit->setPlainText(testingText); m_closeButton->setText(tr("Stop Test")); m_testProcessRunner = SshRemoteProcessRunner::create(m_config->sshParameters()); - connect(m_testProcessRunner.data(), SIGNAL(connectionError(Core::SshError)), + connect(m_testProcessRunner.data(), SIGNAL(connectionError(Utils::SshError)), this, SLOT(handleConnectionError())); connect(m_testProcessRunner.data(), SIGNAL(processClosed(int)), this, SLOT(handleTestProcessFinished(int))); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.h b/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.h index 668ff492bddd072600df5c4bf380e8db7f31bb45..a9c56d80040185fe962daec28e21197179f4ef5c 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoconfigtestdialog.h @@ -43,9 +43,9 @@ class QPushButton; class Ui_MaemoConfigTestDialog; QT_END_NAMESPACE -namespace Core { +namespace Utils { class SshRemoteProcessRunner; -} // namespace Core +} // namespace Utils namespace Qt4ProjectManager { namespace Internal { @@ -83,7 +83,7 @@ private: QPushButton *m_closeButton; const QSharedPointer<const MaemoDeviceConfig> m_config; - QSharedPointer<Core::SshRemoteProcessRunner> m_testProcessRunner; + QSharedPointer<Utils::SshRemoteProcessRunner> m_testProcessRunner; QString m_deviceTestOutput; bool m_qtVersionOk; MaemoUsedPortsGatherer *const m_portsGatherer; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.cpp index 9ac94b2bdd448d1e8de676641d1cb163b61c2732..16586e5fdd2e2577589bb272b3fece92a232ea61 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.cpp @@ -41,7 +41,7 @@ #include "maemousedportsgatherer.h" #include "qt4maemotarget.h" -#include <coreplugin/ssh/sftpchannel.h> +#include <utils/ssh/sftpchannel.h> #include <debugger/debuggerplugin.h> #include <debugger/debuggerstartparameters.h> #include <debugger/debuggerrunner.h> @@ -54,7 +54,7 @@ #define ASSERT_STATE(state) ASSERT_STATE_GENERIC(State, state, m_state) -using namespace Core; +using namespace Utils; using namespace Debugger; using namespace ProjectExplorer; @@ -205,8 +205,8 @@ void MaemoDebugSupport::startExecution() SLOT(handleSftpChannelInitialized())); connect(m_uploader.data(), SIGNAL(initializationFailed(QString)), this, SLOT(handleSftpChannelInitializationFailed(QString))); - connect(m_uploader.data(), SIGNAL(finished(Core::SftpJobId, QString)), - this, SLOT(handleSftpJobFinished(Core::SftpJobId, QString))); + connect(m_uploader.data(), SIGNAL(finished(Utils::SftpJobId, QString)), + this, SLOT(handleSftpJobFinished(Utils::SftpJobId, QString))); m_uploader->initialize(); } else { setState(DumpersUploaded); @@ -244,7 +244,7 @@ void MaemoDebugSupport::handleSftpChannelInitializationFailed(const QString &err handleAdapterSetupFailed(error); } -void MaemoDebugSupport::handleSftpJobFinished(Core::SftpJobId job, +void MaemoDebugSupport::handleSftpJobFinished(Utils::SftpJobId job, const QString &error) { if (m_state == Inactive) diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.h b/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.h index 775f9b9400b4427dcf7e4f8388701972cb9907c1..a7051989d070bbfa48286a0b047d6f42750b7063 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodebugsupport.h @@ -37,7 +37,7 @@ #include "maemorunconfiguration.h" -#include <coreplugin/ssh/sftpdefs.h> +#include <utils/ssh/sftpdefs.h> #include <utils/environment.h> #include <QtCore/QObject> @@ -77,7 +77,7 @@ private slots: void startExecution(); void handleSftpChannelInitialized(); void handleSftpChannelInitializationFailed(const QString &error); - void handleSftpJobFinished(Core::SftpJobId job, const QString &error); + void handleSftpJobFinished(Utils::SftpJobId job, const QString &error); void handleDebuggingFinished(); void handleRemoteOutput(const QByteArray &output); void handleRemoteErrorOutput(const QByteArray &output); @@ -106,8 +106,8 @@ private: const QString m_dumperLib; const QList<Utils::EnvironmentItem> m_userEnvChanges; - QSharedPointer<Core::SftpChannel> m_uploader; - Core::SftpJobId m_uploadJob; + QSharedPointer<Utils::SftpChannel> m_uploader; + Utils::SftpJobId m_uploadJob; QByteArray m_gdbserverOutput; State m_state; int m_gdbServerPort; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.cpp index af4a34ac689c22825abf03cf0c1fca089bf42fd3..725f2d38bd7535ddf5e867f65dba69b056c9944c 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.cpp @@ -45,9 +45,9 @@ #include "maemousedportsgatherer.h" #include "qt4maemotarget.h" -#include <coreplugin/ssh/sftpchannel.h> -#include <coreplugin/ssh/sshconnection.h> -#include <coreplugin/ssh/sshremoteprocess.h> +#include <utils/ssh/sftpchannel.h> +#include <utils/ssh/sshconnection.h> +#include <utils/ssh/sshremoteprocess.h> #include <projectexplorer/buildconfiguration.h> #include <projectexplorer/projectexplorerconstants.h> @@ -66,6 +66,7 @@ #define ASSERT_STATE(state) ASSERT_STATE_GENERIC(State, state, m_state) using namespace Core; +using namespace Utils; using namespace ProjectExplorer; namespace Qt4ProjectManager { @@ -436,7 +437,7 @@ void MaemoDeployStep::handleSftpChannelInitializationFailed(const QString &error } } -void MaemoDeployStep::handleSftpJobFinished(Core::SftpJobId, +void MaemoDeployStep::handleSftpJobFinished(Utils::SftpJobId, const QString &error) { ASSERT_STATE(QList<State>() << Uploading << StopRequested); @@ -612,8 +613,8 @@ void MaemoDeployStep::prepareSftpConnection() SLOT(handleSftpChannelInitialized())); connect(m_uploader.data(), SIGNAL(initializationFailed(QString)), this, SLOT(handleSftpChannelInitializationFailed(QString))); - connect(m_uploader.data(), SIGNAL(finished(Core::SftpJobId, QString)), - this, SLOT(handleSftpJobFinished(Core::SftpJobId, QString))); + connect(m_uploader.data(), SIGNAL(finished(Utils::SftpJobId, QString)), + this, SLOT(handleSftpJobFinished(Utils::SftpJobId, QString))); connect(m_uploader.data(), SIGNAL(closed()), this, SLOT(handleSftpChannelClosed())); m_uploader->initialize(); @@ -695,7 +696,7 @@ void MaemoDeployStep::connectToDevice() m_connection = SshConnection::create(); connect(m_connection.data(), SIGNAL(connected()), this, SLOT(handleConnected())); - connect(m_connection.data(), SIGNAL(error(Core::SshError)), this, + connect(m_connection.data(), SIGNAL(error(Utils::SshError)), this, SLOT(handleConnectionFailure())); if (canReUse) { handleConnected(); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.h b/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.h index 1c8438283b84e64b78044fb4f92d6d84fb3ceb61..c0a111263443b6f27afc60b37a5b1bb5c4fe7e0d 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeploystep.h @@ -39,7 +39,7 @@ #include "maemodeviceconfigurations.h" #include "maemomountspecification.h" -#include <coreplugin/ssh/sftpdefs.h> +#include <utils/ssh/sftpdefs.h> #include <projectexplorer/buildstep.h> #include <QtCore/QHash> @@ -54,7 +54,7 @@ class QProcess; class QTimer; QT_END_NAMESPACE -namespace Core { +namespace Utils { class SftpChannel; class SshConnection; class SshRemoteProcess; @@ -84,7 +84,7 @@ public: const MaemoDeployable &deployable) const; void setDeployed(const QString &host, const MaemoDeployable &deployable); QSharedPointer<MaemoDeployables> deployables() const { return m_deployables; } - QSharedPointer<Core::SshConnection> sshConnection() const { return m_connection; } + QSharedPointer<Utils::SshConnection> sshConnection() const { return m_connection; } MaemoPortList freePorts() const; bool isDeployToSysrootEnabled() const { return m_deployToSysroot; } @@ -112,7 +112,7 @@ private slots: void handleSysrootInstallerErrorOutput(); void handleSftpChannelInitialized(); void handleSftpChannelInitializationFailed(const QString &error); - void handleSftpJobFinished(Core::SftpJobId job, const QString &error); + void handleSftpJobFinished(Utils::SftpJobId job, const QString &error); void handleSftpChannelClosed(); void handleInstallationFinished(int exitStatus); void handleDeviceInstallerOutput(const QByteArray &output); @@ -162,15 +162,15 @@ private: static const QLatin1String Id; QSharedPointer<MaemoDeployables> m_deployables; - QSharedPointer<Core::SshConnection> m_connection; + QSharedPointer<Utils::SshConnection> m_connection; QProcess *m_sysrootInstaller; - typedef QPair<MaemoDeployable, QSharedPointer<Core::SshRemoteProcess> > DeviceDeployAction; + typedef QPair<MaemoDeployable, QSharedPointer<Utils::SshRemoteProcess> > DeviceDeployAction; QScopedPointer<DeviceDeployAction> m_currentDeviceDeployAction; QList<MaemoDeployable> m_filesToCopy; MaemoRemoteMounter *m_mounter; bool m_deployToSysroot; - QSharedPointer<Core::SftpChannel> m_uploader; - QSharedPointer<Core::SshRemoteProcess> m_deviceInstaller; + QSharedPointer<Utils::SftpChannel> m_uploader; + QSharedPointer<Utils::SshRemoteProcess> m_deviceInstaller; bool m_needsInstall; typedef QPair<MaemoDeployable, QString> DeployablePerHost; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.cpp index ecff8f4797d70889975ec2d612fa876bc8a79e8c..b576080f457cfccb6ebba14ecc3aced4d46fe24e 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.cpp @@ -44,7 +44,7 @@ #include <algorithm> #include <cctype> -typedef Core::SshConnectionParameters::AuthType AuthType; +typedef Utils::SshConnectionParameters::AuthType AuthType; namespace Qt4ProjectManager { namespace Internal { @@ -74,7 +74,7 @@ namespace { const int DefaultGdbServerPortSim(13219); const QString DefaultHostNameHW(QLatin1String("192.168.2.15")); const QString DefaultHostNameSim(QLatin1String("localhost")); - const AuthType DefaultAuthType(Core::SshConnectionParameters::AuthByKey); + const AuthType DefaultAuthType(Utils::SshConnectionParameters::AuthByKey); const int DefaultTimeout(30); const MaemoDeviceConfig::DeviceType DefaultDeviceType(MaemoDeviceConfig::Physical); } @@ -231,8 +231,8 @@ MaemoDeviceConfig::Ptr MaemoDeviceConfig::createHardwareConfig(const QString &na MaemoGlobal::MaemoVersion osVersion, const QString &hostName, const QString privateKeyFilePath, Id &nextId) { - Core::SshConnectionParameters sshParams(Core::SshConnectionParameters::NoProxy); - sshParams.authType = Core::SshConnectionParameters::AuthByKey; + Utils::SshConnectionParameters sshParams(Utils::SshConnectionParameters::NoProxy); + sshParams.authType = Utils::SshConnectionParameters::AuthByKey; sshParams.host = hostName; sshParams.privateKeyFile = privateKeyFilePath; return Ptr(new MaemoDeviceConfig(name, osVersion, Physical, sshParams, nextId)); @@ -241,8 +241,8 @@ MaemoDeviceConfig::Ptr MaemoDeviceConfig::createHardwareConfig(const QString &na MaemoDeviceConfig::Ptr MaemoDeviceConfig::createEmulatorConfig(const QString &name, MaemoGlobal::MaemoVersion osVersion, Id &nextId) { - Core::SshConnectionParameters sshParams(Core::SshConnectionParameters::NoProxy); - sshParams.authType = Core::SshConnectionParameters::AuthByPwd; + Utils::SshConnectionParameters sshParams(Utils::SshConnectionParameters::NoProxy); + sshParams.authType = Utils::SshConnectionParameters::AuthByPwd; sshParams.host = defaultHost(Simulator); sshParams.pwd = defaultQemuPassword(osVersion); return Ptr(new MaemoDeviceConfig(name, osVersion, Simulator, sshParams, nextId)); @@ -250,7 +250,7 @@ MaemoDeviceConfig::Ptr MaemoDeviceConfig::createEmulatorConfig(const QString &na MaemoDeviceConfig::MaemoDeviceConfig(const QString &name, MaemoGlobal::MaemoVersion osVersion, DeviceType devType, - const Core::SshConnectionParameters &sshParams, Id &nextId) + const Utils::SshConnectionParameters &sshParams, Id &nextId) : m_sshParameters(sshParams), m_name(name), m_osVersion(osVersion), @@ -266,7 +266,7 @@ MaemoDeviceConfig::MaemoDeviceConfig(const QString &name, MaemoDeviceConfig::MaemoDeviceConfig(const QSettings &settings, Id &nextId) - : m_sshParameters(Core::SshConnectionParameters::NoProxy), + : m_sshParameters(Utils::SshConnectionParameters::NoProxy), m_name(settings.value(NameKey).toString()), m_osVersion(static_cast<MaemoGlobal::MaemoVersion>(settings.value(OsVersionKey, MaemoGlobal::Maemo5).toInt())), m_type(static_cast<DeviceType>(settings.value(TypeKey, DefaultDeviceType).toInt())), @@ -493,7 +493,7 @@ void MaemoDeviceConfigurations::setConfigurationName(int i, const QString &name) } void MaemoDeviceConfigurations::setSshParameters(int i, - const Core::SshConnectionParameters ¶ms) + const Utils::SshConnectionParameters ¶ms) { Q_ASSERT(i >= 0 && i < rowCount()); m_devConfigs.at(i)->m_sshParameters = params; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.h b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.h index a738e7f7fbc720216e67c8956966fb6c2f7537b5..a84cf79ff2d1e1a0715abb24fc8e5cd7e595df2f 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurations.h @@ -37,7 +37,7 @@ #include "maemoglobal.h" -#include <coreplugin/ssh/sshconnection.h> +#include <utils/ssh/sshconnection.h> #include <QtCore/QAbstractListModel> #include <QtCore/QList> @@ -77,7 +77,7 @@ public: enum DeviceType { Physical, Simulator }; MaemoPortList freePorts() const; - Core::SshConnectionParameters sshParameters() const { return m_sshParameters; } + Utils::SshConnectionParameters sshParameters() const { return m_sshParameters; } QString name() const { return m_name; } MaemoGlobal::MaemoVersion osVersion() const { return m_osVersion; } DeviceType type() const { return m_type; } @@ -98,7 +98,7 @@ private: typedef QSharedPointer<MaemoDeviceConfig> Ptr; MaemoDeviceConfig(const QString &name, MaemoGlobal::MaemoVersion osVersion, - DeviceType type, const Core::SshConnectionParameters &sshParams, + DeviceType type, const Utils::SshConnectionParameters &sshParams, Id &nextId); MaemoDeviceConfig(const QSettings &settings, Id &nextId); MaemoDeviceConfig(const ConstPtr &other); @@ -117,7 +117,7 @@ private: void save(QSettings &settings) const; QString defaultPortsSpec(DeviceType type) const; - Core::SshConnectionParameters m_sshParameters; + Utils::SshConnectionParameters m_sshParameters; QString m_name; MaemoGlobal::MaemoVersion m_osVersion; DeviceType m_type; @@ -154,7 +154,7 @@ public: MaemoGlobal::MaemoVersion osVersion); void removeConfiguration(int index); void setConfigurationName(int i, const QString &name); - void setSshParameters(int i, const Core::SshConnectionParameters ¶ms); + void setSshParameters(int i, const Utils::SshConnectionParameters ¶ms); void setPortsSpec(int i, const QString &portsSpec); void setDefaultDevice(int index); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.cpp index f6b5dfff448131301790394b820c09db10e36d6f..f42353f004bf06c8de29c5f02df400bcdd39613b 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.cpp @@ -44,7 +44,7 @@ #include "maemosshconfigdialog.h" #include <coreplugin/icore.h> -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtCore/QFileInfo> #include <QtCore/QRegExp> @@ -58,6 +58,7 @@ #include <algorithm> using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -204,7 +205,7 @@ void MaemoDeviceConfigurationsSettingsWidget::displayCurrent() m_ui->deviceTypeValueLabel->setText(tr("Emulator (Qemu)")); m_ui->portsLineEdit->setReadOnly(true); } - if (sshParams.authType == Core::SshConnectionParameters::AuthByPwd) + if (sshParams.authType == Utils::SshConnectionParameters::AuthByPwd) m_ui->passwordButton->setChecked(true); else m_ui->keyButton->setChecked(true); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.h b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.h index ff0be87432a1642205642cefc58fecd5f3ee7459..5715e1c885dc3e22560a11e37456a258bc256ea1 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigurationssettingswidget.h @@ -46,7 +46,7 @@ class QLineEdit; class Ui_MaemoDeviceConfigurationsSettingsWidget; QT_END_NAMESPACE -namespace Core { +namespace Utils { class SshRemoteProcessRunner; } diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigwizard.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigwizard.cpp index c117007a9244dc6a9a535cb4fa5be8cfbd6a7270..f56920d3f019c017d5b10f984458fba83c3109bc 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigwizard.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceconfigwizard.cpp @@ -41,7 +41,7 @@ #include "maemodeviceconfigurations.h" #include "maemokeydeployer.h" -#include <coreplugin/ssh/sshkeygenerator.h> +#include <utils/ssh/sshkeygenerator.h> #include <QtCore/QDir> #include <QtCore/QFile> @@ -309,9 +309,9 @@ private: m_ui->keyDirPathChooser->setEnabled(false); m_ui->createKeysButton->setEnabled(false); m_ui->statusLabel->setText(tr("Creating keys ... ")); - Core::SshKeyGenerator keyGenerator; - if (!keyGenerator.generateKeys(Core::SshKeyGenerator::Rsa, - Core::SshKeyGenerator::OpenSsl, 1024)) { + Utils::SshKeyGenerator keyGenerator; + if (!keyGenerator.generateKeys(Utils::SshKeyGenerator::Rsa, + Utils::SshKeyGenerator::OpenSsl, 1024)) { QMessageBox::critical(this, tr("Can't Create Keys"), tr("Key creation failed: %1").arg(keyGenerator.error())); enableInput(); @@ -402,11 +402,11 @@ private: Q_SLOT void deployKey() { - using namespace Core; + using namespace Utils; m_ui->deviceAddressLineEdit->setEnabled(false); m_ui->passwordLineEdit->setEnabled(false); m_ui->deployButton->setEnabled(false); - Core::SshConnectionParameters sshParams(SshConnectionParameters::NoProxy); + Utils::SshConnectionParameters sshParams(SshConnectionParameters::NoProxy); sshParams.authType = SshConnectionParameters::AuthByPwd; sshParams.host = hostAddress(); sshParams.port = MaemoDeviceConfig::defaultSshPort(MaemoDeviceConfig::Physical); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.cpp index 8a8581c7d40a0efa8d751cdf29393ed52e7a3dcb..f683b28a3af14e34274341394318ce6e1aaa4e34 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.cpp @@ -38,7 +38,7 @@ #include "maemoglobal.h" #include "maemorunconfiguration.h" -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> namespace Qt4ProjectManager { namespace Internal { @@ -63,13 +63,13 @@ void MaemoDeviceEnvReader::start() return; m_stop = false; if (!m_remoteProcessRunner - || m_remoteProcessRunner->connection()->state() != Core::SshConnection::Connected + || m_remoteProcessRunner->connection()->state() != Utils::SshConnection::Connected || m_remoteProcessRunner->connection()->connectionParameters() != m_devConfig->sshParameters()) { m_remoteProcessRunner - = Core::SshRemoteProcessRunner::create(m_devConfig->sshParameters()); + = Utils::SshRemoteProcessRunner::create(m_devConfig->sshParameters()); } connect(m_remoteProcessRunner.data(), - SIGNAL(connectionError(Core::SshError)), this, + SIGNAL(connectionError(Utils::SshError)), this, SLOT(handleConnectionFailure())); connect(m_remoteProcessRunner.data(), SIGNAL(processClosed(int)), this, SLOT(remoteProcessFinished(int))); @@ -115,16 +115,16 @@ void MaemoDeviceEnvReader::handleCurrentDeviceConfigChanged() void MaemoDeviceEnvReader::remoteProcessFinished(int exitCode) { - Q_ASSERT(exitCode == Core::SshRemoteProcess::FailedToStart - || exitCode == Core::SshRemoteProcess::KilledBySignal - || exitCode == Core::SshRemoteProcess::ExitedNormally); + Q_ASSERT(exitCode == Utils::SshRemoteProcess::FailedToStart + || exitCode == Utils::SshRemoteProcess::KilledBySignal + || exitCode == Utils::SshRemoteProcess::ExitedNormally); if (m_stop) return; disconnect(m_remoteProcessRunner.data(), 0, this, 0); m_env.clear(); - if (exitCode == Core::SshRemoteProcess::ExitedNormally) { + if (exitCode == Utils::SshRemoteProcess::ExitedNormally) { if (!m_remoteOutput.isEmpty()) { m_env = Utils::Environment(m_remoteOutput.split(QLatin1Char('\n'), QString::SkipEmptyParts)); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.h b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.h index 3933aff459ed0da4a68b957e04664f30c0d9b920..a36c1eec812bf31a799c2885be4145216d59e523 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemodeviceenvreader.h @@ -40,7 +40,7 @@ #include <QtCore/QObject> #include <QtCore/QSharedPointer> -namespace Core { +namespace Utils { class SshRemoteProcessRunner; } @@ -83,7 +83,7 @@ private: Utils::Environment m_env; QSharedPointer<const MaemoDeviceConfig> m_devConfig; MaemoRunConfiguration *m_runConfig; - QSharedPointer<Core::SshRemoteProcessRunner> m_remoteProcessRunner; + QSharedPointer<Utils::SshRemoteProcessRunner> m_remoteProcessRunner; }; } // Internal diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.cpp index 343c5676a9fac132c2126f229df83b487d818d86..178bbc48968814e5c08e9976c58c78c06e70e278 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.cpp @@ -39,7 +39,7 @@ #include <projectexplorer/projectexplorerconstants.h> #include <coreplugin/filemanager.h> -#include <coreplugin/ssh/sshconnection.h> +#include <utils/ssh/sshconnection.h> #include <qt4projectmanager/qt4projectmanagerconstants.h> #include <qt4projectmanager/qtversionmanager.h> #include <utils/environment.h> @@ -138,18 +138,18 @@ QString MaemoGlobal::remoteEnvironment(const QList<Utils::EnvironmentItem> &list return env.mid(0, env.size() - 1); } -QString MaemoGlobal::failedToConnectToServerMessage(const Core::SshConnection::Ptr &connection, +QString MaemoGlobal::failedToConnectToServerMessage(const Utils::SshConnection::Ptr &connection, const MaemoDeviceConfig::ConstPtr &deviceConfig) { QString errorMsg = tr("Could not connect to host: %1") .arg(connection->errorString()); if (deviceConfig->type() == MaemoDeviceConfig::Simulator) { - if (connection->errorState() == Core::SshTimeoutError - || connection->errorState() == Core::SshSocketError) { + if (connection->errorState() == Utils::SshTimeoutError + || connection->errorState() == Utils::SshSocketError) { errorMsg += tr("\nDid you start Qemu?"); } - } else if (connection->errorState() == Core::SshTimeoutError) { + } else if (connection->errorState() == Utils::SshTimeoutError) { errorMsg += tr("\nIs the device connected and set up for network access?"); } return errorMsg; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.h b/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.h index 682862ae5e424db3457db864bf1ba25337aa1643..72afdc52d1bfd0a571769efaa5258075efd4235e 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoglobal.h @@ -51,7 +51,7 @@ class QProcess; class QString; QT_END_NAMESPACE -namespace Core { class SshConnection; } +namespace Utils { class SshConnection; } namespace Qt4ProjectManager { class QtVersion; namespace Internal { @@ -82,7 +82,7 @@ public: static QString remoteCommandPrefix(const QString &commandFilePath); static QString remoteEnvironment(const QList<Utils::EnvironmentItem> &list); static QString remoteSourceProfilesCommand(); - static QString failedToConnectToServerMessage(const QSharedPointer<Core::SshConnection> &connection, + static QString failedToConnectToServerMessage(const QSharedPointer<Utils::SshConnection> &connection, const QSharedPointer<const MaemoDeviceConfig> &deviceConfig); static QString deviceConfigurationName(const QSharedPointer<const MaemoDeviceConfig> &devConf); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.cpp index ddc60612225c9b19b02971020bf7fbc44bc8246f..679feffce5c888f9bbf4ecb39dec4345477bbe04 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.cpp @@ -33,11 +33,11 @@ ****************************************************************************/ #include "maemokeydeployer.h" -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtCore/QFile> -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -68,7 +68,7 @@ void MaemoKeyDeployer::deployPublicKey(const SshConnectionParameters &sshParams, return; } - connect(m_deployProcess.data(), SIGNAL(connectionError(Core::SshError)), this, + connect(m_deployProcess.data(), SIGNAL(connectionError(Utils::SshError)), this, SLOT(handleConnectionFailure())); connect(m_deployProcess.data(), SIGNAL(processClosed(int)), this, SLOT(handleKeyUploadFinished(int))); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.h b/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.h index c0d4b15a9284025108b96d857502c7044acd5038..30bc07d79e20c4887dfd8ad3d6aa2f42cbaa9c88 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemokeydeployer.h @@ -37,7 +37,7 @@ #include <QtCore/QObject> #include <QtCore/QSharedPointer> -namespace Core { +namespace Utils { struct SshConnectionParameters; class SshRemoteProcessRunner; } @@ -52,7 +52,7 @@ public: explicit MaemoKeyDeployer(QObject *parent = 0); ~MaemoKeyDeployer(); - void deployPublicKey(const Core::SshConnectionParameters &sshParams, + void deployPublicKey(const Utils::SshConnectionParameters &sshParams, const QString &keyFilePath); void stopDeployment(); @@ -67,7 +67,7 @@ private slots: private: void cleanup(); - QSharedPointer<Core::SshRemoteProcessRunner> m_deployProcess; + QSharedPointer<Utils::SshRemoteProcessRunner> m_deployProcess; }; } // namespace Internal diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.cpp index 000128b94044a8206853c3329ccd58fb45b50195..5fce2a4cbbbbff558f47ad4e2f67db5f32657c68 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.cpp @@ -54,6 +54,7 @@ #define ASSERT_STATE(state) ASSERT_STATE_GENERIC(State, state, m_state) using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -371,7 +372,7 @@ void MaemoPublisherFremantleFree::uploadPackage() m_uploader = SshRemoteProcessRunner::create(m_sshParams); connect(m_uploader.data(), SIGNAL(processStarted()), SLOT(handleScpStarted())); - connect(m_uploader.data(), SIGNAL(connectionError(Core::SshError)), + connect(m_uploader.data(), SIGNAL(connectionError(Utils::SshError)), SLOT(handleConnectionError())); connect(m_uploader.data(), SIGNAL(processClosed(int)), SLOT(handleUploadJobFinished(int))); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.h b/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.h index b05d79d1e314ef7d96fbffc8b93153e4f46a46ba..c74e969c2f21a77d3d359cfb820adec05b14590b 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemopublisherfremantlefree.h @@ -33,7 +33,7 @@ #ifndef MAEMOPUBLISHERFREMANTLEFREE_H #define MAEMOPUBLISHERFREMANTLEFREE_H -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtCore/QObject> #include <QtCore/QProcess> @@ -112,9 +112,9 @@ private: State m_state; QString m_tmpProjectDir; QProcess *m_process; - Core::SshConnectionParameters m_sshParams; + Utils::SshConnectionParameters m_sshParams; QString m_remoteDir; - QSharedPointer<Core::SshRemoteProcessRunner> m_uploader; + QSharedPointer<Utils::SshRemoteProcessRunner> m_uploader; QByteArray m_scpOutput; QList<QString> m_filesToUpload; QString m_resultString; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.cpp index a60f3d49c4692b34512ab210d879da22e8fcee4b..e18cc00c828572c2b4ce9b53c6df5833e8abe1cb 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.cpp @@ -37,8 +37,8 @@ #include "maemousedportsgatherer.h" #include "qt4maemotarget.h" -#include <coreplugin/ssh/sshconnection.h> -#include <coreplugin/ssh/sshremoteprocess.h> +#include <utils/ssh/sshconnection.h> +#include <utils/ssh/sshremoteprocess.h> #include <qt4projectmanager/qt4buildconfiguration.h> #include <utils/qtcassert.h> @@ -46,7 +46,7 @@ #define ASSERT_STATE(state) ASSERT_STATE_GENERIC(State, state, m_state) -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.h b/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.h index 7aa2226b47af5ec65145e255ae9b12a256c25580..a73d4ddb10a8ba2a58b87fd08cf2fb67e634968d 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoremotemounter.h @@ -45,7 +45,7 @@ QT_FORWARD_DECLARE_CLASS(QTimer) -namespace Core { +namespace Utils { class SftpChannel; class SshConnection; class SshRemoteProcess; @@ -64,7 +64,7 @@ public: ~MaemoRemoteMounter(); // Must already be connected. - void setConnection(const QSharedPointer<Core::SshConnection> &connection); + void setConnection(const QSharedPointer<Utils::SshConnection> &connection); void setBuildConfiguration(const Qt4BuildConfiguration *bc); void addMountSpecification(const MaemoMountSpecification &mountSpec, @@ -120,10 +120,10 @@ private: int remotePort; }; - QSharedPointer<Core::SshConnection> m_connection; + QSharedPointer<Utils::SshConnection> m_connection; QList<MountInfo> m_mountSpecs; - QSharedPointer<Core::SshRemoteProcess> m_mountProcess; - QSharedPointer<Core::SshRemoteProcess> m_unmountProcess; + QSharedPointer<Utils::SshRemoteProcess> m_mountProcess; + QSharedPointer<Utils::SshRemoteProcess> m_unmountProcess; typedef QSharedPointer<QProcess> ProcPtr; QList<ProcPtr> m_utfsServers; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.cpp index 1d27d0852fe9233e0ba02d00f5b80d98fd72631e..611001e0dde3df94b194475d075226fca17a5dea 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.cpp @@ -43,11 +43,11 @@ #include "maemodeviceconfigurations.h" -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> #include <QtCore/QStringList> -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -114,7 +114,7 @@ void MaemoRemoteProcessList::startProcess(const QByteArray &cmdLine, stop(); } m_state = newState; - connect(m_process.data(), SIGNAL(connectionError(Core::SshError)), + connect(m_process.data(), SIGNAL(connectionError(Utils::SshError)), SLOT(handleConnectionError())); connect(m_process.data(), SIGNAL(processOutputAvailable(QByteArray)), SLOT(handleRemoteStdOut(QByteArray))); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.h b/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.h index 81fddb25d9a95584f37986fe9a42c590f03424cb..edc22df5e916c4838826d2ffc0deb002524b635f 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemoremoteprocesslist.h @@ -47,7 +47,7 @@ #include <QtCore/QList> #include <QtCore/QSharedPointer> #include <QtCore/QString> -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> namespace Qt4ProjectManager { namespace Internal { @@ -87,7 +87,7 @@ private: void stop(); void startProcess(const QByteArray &cmdLine, State newState); - const QSharedPointer<Core::SshRemoteProcessRunner> m_process; + const QSharedPointer<Utils::SshRemoteProcessRunner> m_process; QByteArray m_remoteStdout; QByteArray m_remoteStderr; QString m_errorMsg; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.cpp index a339c160dc8a31c23a4e0f8bd9694d4f969a1cd3..6775e2fb6ab3a1ee1f4f50062ef1932d02d961e5 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.cpp @@ -36,7 +36,7 @@ #include "maemodeviceconfigurations.h" -#include <coreplugin/ssh/sshkeygenerator.h> +#include <utils/ssh/sshkeygenerator.h> #include <QtCore/QDir> #include <QtGui/QApplication> @@ -45,7 +45,7 @@ #include <QtGui/QMessageBox> #include <QtNetwork/QHostInfo> -using namespace Core; +using namespace Utils; using namespace Qt4ProjectManager::Internal; MaemoSshConfigDialog::MaemoSshConfigDialog(QWidget *parent) diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.h b/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.h index 4073ff9e4034d827764371926af864e8544971d6..a0f7469785b1a5ec22dda32c86aabac110584b60 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemosshconfigdialog.h @@ -40,7 +40,7 @@ #include <QtCore/QScopedPointer> #include <QtGui/QDialog> -namespace Core { +namespace Utils { class SshKeyGenerator; } @@ -69,7 +69,7 @@ private: private: QString home; - QScopedPointer<Core::SshKeyGenerator> m_keyGenerator; + QScopedPointer<Utils::SshKeyGenerator> m_keyGenerator; Ui::MaemoSshConfigDialog m_ui; }; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.cpp index 556b5fb541dac1109acc167e1fad4a0ff0b78aab..fd9a03a937072e9f06d20ed4e4742d18b38dda30 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.cpp @@ -42,8 +42,8 @@ #include "maemorunconfiguration.h" #include "maemousedportsgatherer.h" -#include <coreplugin/ssh/sshconnection.h> -#include <coreplugin/ssh/sshremoteprocess.h> +#include <utils/ssh/sshconnection.h> +#include <utils/ssh/sshremoteprocess.h> #include <QtCore/QFileInfo> @@ -51,7 +51,7 @@ #define ASSERT_STATE(state) ASSERT_STATE_GENERIC(State, state, m_state) -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -125,7 +125,7 @@ void MaemoSshRunner::start() m_connection = SshConnection::create(); connect(m_connection.data(), SIGNAL(connected()), this, SLOT(handleConnected())); - connect(m_connection.data(), SIGNAL(error(Core::SshError)), this, + connect(m_connection.data(), SIGNAL(error(Utils::SshError)), this, SLOT(handleConnectionFailure())); if (reUse) { handleConnected(); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.h b/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.h index f7b64a29f68bd353879d10b1b788cfbaa66ddfd5..edf436be95e19ac44062d5bb11bf1673af7b3288 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemosshrunner.h @@ -44,7 +44,7 @@ #include <QtCore/QSharedPointer> #include <QtCore/QStringList> -namespace Core { +namespace Utils { class SshConnection; class SshRemoteProcess; } @@ -68,7 +68,7 @@ public: void startExecution(const QByteArray &remoteCall); - QSharedPointer<Core::SshConnection> connection() const { return m_connection; } + QSharedPointer<Utils::SshConnection> connection() const { return m_connection; } const MaemoUsedPortsGatherer *usedPortsGatherer() const { return m_portsGatherer; } MaemoPortList *freePorts() { return &m_freePorts; } QString remoteExecutable() const { return m_remoteExecutable; } @@ -121,9 +121,9 @@ private: const MaemoPortList m_initialFreePorts; QList<MaemoMountSpecification> m_mountSpecs; - QSharedPointer<Core::SshConnection> m_connection; - QSharedPointer<Core::SshRemoteProcess> m_runner; - QSharedPointer<Core::SshRemoteProcess> m_cleaner; + QSharedPointer<Utils::SshConnection> m_connection; + QSharedPointer<Utils::SshRemoteProcess> m_runner; + QSharedPointer<Utils::SshRemoteProcess> m_cleaner; QStringList m_procsToKill; MaemoPortList m_freePorts; diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.cpp b/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.cpp index 1ebd7baed84370ecef5088c7108d922dc9a23e3d..3cb2eaee174b8601348a730b82666d31671eca57 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.cpp +++ b/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.cpp @@ -35,9 +35,9 @@ #include "maemoglobal.h" -#include <coreplugin/ssh/sshremoteprocessrunner.h> +#include <utils/ssh/sshremoteprocessrunner.h> -using namespace Core; +using namespace Utils; namespace Qt4ProjectManager { namespace Internal { @@ -49,7 +49,7 @@ MaemoUsedPortsGatherer::MaemoUsedPortsGatherer(QObject *parent) : MaemoUsedPortsGatherer::~MaemoUsedPortsGatherer() {} -void MaemoUsedPortsGatherer::start(const Core::SshConnection::Ptr &connection, +void MaemoUsedPortsGatherer::start(const Utils::SshConnection::Ptr &connection, const MaemoPortList &portList) { if (m_running) @@ -58,7 +58,7 @@ void MaemoUsedPortsGatherer::start(const Core::SshConnection::Ptr &connection, m_remoteStdout.clear(); m_remoteStderr.clear(); m_procRunner = SshRemoteProcessRunner::create(connection); - connect(m_procRunner.data(), SIGNAL(connectionError(Core::SshError)), + connect(m_procRunner.data(), SIGNAL(connectionError(Utils::SshError)), SLOT(handleConnectionError())); connect(m_procRunner.data(), SIGNAL(processClosed(int)), SLOT(handleProcessClosed(int))); diff --git a/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.h b/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.h index b0137d9fe5d81f6bbaef89e7b387248f520408a5..73ae9ac4ea85b81671ae7db05f17a8cbafcff938 100644 --- a/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.h +++ b/src/plugins/qt4projectmanager/qt-maemo/maemousedportsgatherer.h @@ -41,7 +41,7 @@ #include <QtCore/QSharedPointer> #include <QtCore/QString> -namespace Core { +namespace Utils { class SshConnection; class SshRemoteProcessRunner; } @@ -55,7 +55,7 @@ class MaemoUsedPortsGatherer : public QObject public: explicit MaemoUsedPortsGatherer(QObject *parent = 0); ~MaemoUsedPortsGatherer(); - void start(const QSharedPointer<Core::SshConnection> &connection, + void start(const QSharedPointer<Utils::SshConnection> &connection, const MaemoPortList &portList); void stop(); int getNextFreePort(MaemoPortList *freePorts) const; // returns -1 if no more are left @@ -74,7 +74,7 @@ private slots: private: void setupUsedPorts(); - QSharedPointer<Core::SshRemoteProcessRunner> m_procRunner; + QSharedPointer<Utils::SshRemoteProcessRunner> m_procRunner; QList<int> m_usedPorts; QByteArray m_remoteStdout; QByteArray m_remoteStderr;