summaryrefslogtreecommitdiffstats
path: root/Source/QtDialog/QCMake.h
diff options
context:
space:
mode:
authorClinton Stimpson <clinton@elemtech.com>2007-11-03 14:30:52 (GMT)
committerClinton Stimpson <clinton@elemtech.com>2007-11-03 14:30:52 (GMT)
commit77ad85a6ab00959b972f5f2ad86382e2161b92b6 (patch)
treedffe50dd916306eefcefd39e0f7fb20dc375bc27 /Source/QtDialog/QCMake.h
parentc139a096c7cb73a8184b69f20a837d97c00b5a96 (diff)
downloadCMake-77ad85a6ab00959b972f5f2ad86382e2161b92b6.zip
CMake-77ad85a6ab00959b972f5f2ad86382e2161b92b6.tar.gz
CMake-77ad85a6ab00959b972f5f2ad86382e2161b92b6.tar.bz2
ENH: Add interrupt button near progress bar.
Implement help button. Implement cancel button. Add scrollable output window. Replace ON/OFF & combobox editors with checkboxes. Tab/backtab in cache table jumps between values (not names and values) Add tooltips to show help strings. Add application icon and qtmain for Windows. BUG: Fix save of cache values on configure.
Diffstat (limited to 'Source/QtDialog/QCMake.h')
-rw-r--r--Source/QtDialog/QCMake.h38
1 files changed, 31 insertions, 7 deletions
diff --git a/Source/QtDialog/QCMake.h b/Source/QtDialog/QCMake.h
index 15c13ec..38d94e6 100644
--- a/Source/QtDialog/QCMake.h
+++ b/Source/QtDialog/QCMake.h
@@ -20,17 +20,19 @@
#include <QObject>
#include <QString>
+#include <QVariant>
#include <QList>
#include <QMetaType>
class cmake;
-// struct to represent cache properties in Qt
+/// struct to represent cache properties in Qt
+/// Value is of type String or Bool
struct QCMakeCacheProperty
{
enum PropertyType { BOOL, PATH, FILEPATH, STRING };
QString Key;
- QString Value;
+ QVariant Value;
QString Help;
PropertyType Type;
bool Advanced;
@@ -41,9 +43,9 @@ Q_DECLARE_METATYPE(QCMakeCacheProperty)
typedef QList<QCMakeCacheProperty> QCMakeCachePropertyList;
Q_DECLARE_METATYPE(QCMakeCachePropertyList)
-// Qt API for CMake library.
-// Wrapper like class allows for easier integration with
-// Qt features such as, signal/slot connections, multi-threading, etc..
+/// Qt API for CMake library.
+/// Wrapper like class allows for easier integration with
+/// Qt features such as, signal/slot connections, multi-threading, etc..
class QCMake : public QObject
{
Q_OBJECT
@@ -52,31 +54,53 @@ public:
~QCMake();
public slots:
+ /// load the cache file in a directory
void loadCache(const QString& dir);
+ /// set the source directory containing the source
void setSourceDirectory(const QString& dir);
+ /// set the binary directory to build in
void setBinaryDirectory(const QString& dir);
+ /// set the desired generator to use
void setGenerator(const QString& generator);
+ /// do the configure step
void configure();
+ /// generate the files
void generate();
+ /// set the property values
void setProperties(const QCMakeCachePropertyList&);
+ /// interrupt the configure or generate process
void interrupt();
public:
+ /// get the list of cache properties
QCMakeCachePropertyList properties();
+ /// get the current binary directory
QString binaryDirectory();
+ /// get the current source directory
QString sourceDirectory();
+ /// get the current generator
QString generator();
+ /// get the available generators
+ QStringList availableGenerators();
signals:
+ /// signal when properties change (during read from disk or configure process)
void propertiesChanged(const QCMakeCachePropertyList& vars);
+ /// signal when the generator changes
void generatorChanged(const QString& gen);
+ /// signal when there is an error message
void error(const QString& title, const QString& message, bool*);
+ /// signal when the source directory changes (binary directory already
+ /// containing a CMakeCache.txt file)
void sourceDirChanged(const QString& dir);
+ /// signal for progress events
void progressChanged(const QString& msg, float percent);
+ /// signal when configure is done
void configureDone(int error);
+ /// signal when generate is done
void generateDone(int error);
- void configureReady();
- void generateReady();
+ /// signal when there is an output message
+ void outputMessage(const QString& msg);
protected:
cmake* CMakeInstance;