forked from qt-creator/qt-creator
move abstractprocess and consoleprocess to libs/utils/
will use it also in the debugger, and pulling it in from projectexplorer just seems wrong.
This commit is contained in:
@@ -30,12 +30,14 @@
|
||||
#ifndef ABSTRACTPROCESS_H
|
||||
#define ABSTRACTPROCESS_H
|
||||
|
||||
#include "utils_global.h"
|
||||
|
||||
#include <QtCore/QStringList>
|
||||
|
||||
namespace ProjectExplorer {
|
||||
namespace Internal {
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
|
||||
class AbstractProcess
|
||||
class QWORKBENCH_UTILS_EXPORT AbstractProcess
|
||||
{
|
||||
public:
|
||||
AbstractProcess() {}
|
||||
@@ -62,8 +64,8 @@ private:
|
||||
QStringList m_environment;
|
||||
};
|
||||
|
||||
} //namespace Internal
|
||||
} //namespace Qt4ProjectManager
|
||||
} //namespace Utils
|
||||
} //namespace Core
|
||||
|
||||
#endif // ABSTRACTPROCESS_H
|
||||
|
||||
@@ -30,6 +30,8 @@
|
||||
#ifndef CONSOLEPROCESS_H
|
||||
#define CONSOLEPROCESS_H
|
||||
|
||||
#include "abstractprocess.h"
|
||||
|
||||
#include <QtCore/QObject>
|
||||
#include <QtCore/QString>
|
||||
#include <QtCore/QStringList>
|
||||
@@ -40,13 +42,10 @@
|
||||
class QWinEventNotifier;
|
||||
#endif
|
||||
|
||||
#include "abstractprocess.h"
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
|
||||
|
||||
namespace ProjectExplorer {
|
||||
namespace Internal {
|
||||
|
||||
class ConsoleProcess : public QObject, public AbstractProcess
|
||||
class QWORKBENCH_UTILS_EXPORT ConsoleProcess : public QObject, public AbstractProcess
|
||||
{
|
||||
Q_OBJECT
|
||||
|
||||
@@ -81,7 +80,7 @@ private slots:
|
||||
private:
|
||||
PROCESS_INFORMATION *m_pid;
|
||||
QWinEventNotifier *processFinishedNotifier;
|
||||
#elif defined(Q_OS_UNIX)
|
||||
#else
|
||||
private:
|
||||
QProcess *m_process;
|
||||
private slots:
|
||||
@@ -90,7 +89,7 @@ private slots:
|
||||
|
||||
};
|
||||
|
||||
} //namespace Internal
|
||||
} //namespace Qt4ProjectManager
|
||||
} //namespace Utils
|
||||
} //namespace Core
|
||||
|
||||
#endif
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
#include "consoleprocess.h"
|
||||
|
||||
using namespace ProjectExplorer::Internal;
|
||||
using namespace Core::Utils;
|
||||
|
||||
ConsoleProcess::ConsoleProcess(QObject *parent)
|
||||
: QObject(parent)
|
||||
@@ -27,15 +27,15 @@
|
||||
**
|
||||
**************************************************************************/
|
||||
|
||||
#include "consoleprocess.h"
|
||||
|
||||
#include <QtCore/QDir>
|
||||
#include <QtCore/private/qwineventnotifier_p.h>
|
||||
#include <QtCore/QAbstractEventDispatcher>
|
||||
|
||||
#include <Tlhelp32.h>
|
||||
|
||||
#include "consoleprocess.h"
|
||||
|
||||
using namespace ProjectExplorer::Internal;
|
||||
using namespace Core::Utils;
|
||||
|
||||
ConsoleProcess::ConsoleProcess(QObject *parent)
|
||||
: QObject(parent)
|
||||
@@ -25,6 +25,9 @@ SOURCES += \
|
||||
submiteditorwidget.cpp \
|
||||
synchronousprocess.cpp
|
||||
|
||||
win32:SOURCES += consoleprocess_win.cpp
|
||||
else:SOURCES += consoleprocess_unix.cpp
|
||||
|
||||
HEADERS += \
|
||||
utils_global.h \
|
||||
reloadpromptutils.h \
|
||||
@@ -45,6 +48,8 @@ HEADERS += \
|
||||
fancylineedit.h \
|
||||
qtcolorbutton.h \
|
||||
submiteditorwidget.h \
|
||||
abstractprocess.h \
|
||||
consoleprocess.h \
|
||||
synchronousprocess.h
|
||||
|
||||
FORMS += filewizardpage.ui \
|
||||
|
||||
@@ -37,10 +37,15 @@
|
||||
#include <QtCore/QTextCodec>
|
||||
#endif
|
||||
|
||||
namespace Core {
|
||||
namespace Utils {
|
||||
class ConsoleProcess;
|
||||
}
|
||||
}
|
||||
|
||||
namespace ProjectExplorer {
|
||||
namespace Internal {
|
||||
|
||||
class ConsoleProcess;
|
||||
class WinGuiProcess;
|
||||
|
||||
class ApplicationLauncher : public QObject
|
||||
@@ -84,7 +89,7 @@ private slots:
|
||||
|
||||
private:
|
||||
QProcess *m_guiProcess;
|
||||
ConsoleProcess *m_consoleProcess;
|
||||
Core::Utils::ConsoleProcess *m_consoleProcess;
|
||||
Mode m_currentMode;
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
|
||||
@@ -34,6 +34,7 @@
|
||||
#include <QDebug>
|
||||
|
||||
using namespace ProjectExplorer::Internal;
|
||||
using namespace Core::Utils;
|
||||
|
||||
ApplicationLauncher::ApplicationLauncher(QObject *parent)
|
||||
: QObject(parent)
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
#include <QtCore/QTimer>
|
||||
|
||||
using namespace ProjectExplorer::Internal;
|
||||
using namespace Core::Utils;
|
||||
|
||||
ApplicationLauncher::ApplicationLauncher(QObject *parent)
|
||||
: QObject(parent)
|
||||
|
||||
@@ -5,6 +5,8 @@ QT += xml \
|
||||
include(../../qworkbenchplugin.pri)
|
||||
include(projectexplorer_dependencies.pri)
|
||||
include(../../shared/scriptwrapper/scriptwrapper.pri)
|
||||
include(../../libs/utils/utils.pri)
|
||||
INCLUDEPATH += $$PWD/../../libs/utils
|
||||
HEADERS += projectexplorer.h \
|
||||
projectexplorer_export.h \
|
||||
projectwindow.h \
|
||||
@@ -37,8 +39,6 @@ HEADERS += projectexplorer.h \
|
||||
editorsettingspropertiespage.h \
|
||||
runconfiguration.h \
|
||||
applicationlauncher.h \
|
||||
consoleprocess.h \
|
||||
abstractprocess.h \
|
||||
applicationrunconfiguration.h \
|
||||
runsettingspropertiespage.h \
|
||||
projecttreewidget.h \
|
||||
@@ -114,12 +114,10 @@ FORMS += dependenciespanel.ui \
|
||||
buildstepspage.ui \
|
||||
removefiledialog.ui
|
||||
win32 {
|
||||
SOURCES += consoleprocess_win.cpp \
|
||||
applicationlauncher_win.cpp \
|
||||
SOURCES += applicationlauncher_win.cpp \
|
||||
winguiprocess.cpp
|
||||
HEADERS += winguiprocess.h
|
||||
}
|
||||
else:unix:SOURCES += consoleprocess_unix.cpp \
|
||||
applicationlauncher_x11.cpp
|
||||
else:unix:SOURCES += applicationlauncher_x11.cpp
|
||||
RESOURCES += projectexplorer.qrc
|
||||
DEFINES += PROJECTEXPLORER_LIBRARY
|
||||
|
||||
@@ -37,6 +37,8 @@
|
||||
|
||||
#include <windows.h>
|
||||
|
||||
using namespace Core::Utils;
|
||||
|
||||
namespace ProjectExplorer {
|
||||
namespace Internal {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user