summaryrefslogtreecommitdiffstats
path: root/Source/QtDialog/AddCacheEntry.h
diff options
context:
space:
mode:
authorSergey Zolotarev <sryze@yandex.com>2014-01-13 10:28:16 (GMT)
committerBrad King <brad.king@kitware.com>2014-01-16 14:23:36 (GMT)
commitcfec180d66a7210606c5274e6ba3bb86a1e197a7 (patch)
treeed13abe0f993ac2b9e204da65d5e7c1e892e9e24 /Source/QtDialog/AddCacheEntry.h
parent9f6b633f37bebecc989cc8fc026da999148038f9 (diff)
downloadCMake-cfec180d66a7210606c5274e6ba3bb86a1e197a7.zip
CMake-cfec180d66a7210606c5274e6ba3bb86a1e197a7.tar.gz
CMake-cfec180d66a7210606c5274e6ba3bb86a1e197a7.tar.bz2
cmake-gui: Remember variable type in Add Entry
Store variable types together with their names in the variable completion list so that the type is automatically recovered when you select a variable. Keep variable names and types in separate lists. This removes the :TYPE string from completion list and the Name field and makes variable search easier. The variable names and types are now kept in two different settings - AddVariableNames and AddVariableTypes. Drop the old AddVariableCompletionEntries setting.
Diffstat (limited to 'Source/QtDialog/AddCacheEntry.h')
-rw-r--r--Source/QtDialog/AddCacheEntry.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/Source/QtDialog/AddCacheEntry.h b/Source/QtDialog/AddCacheEntry.h
index e219d4e..38c3a74 100644
--- a/Source/QtDialog/AddCacheEntry.h
+++ b/Source/QtDialog/AddCacheEntry.h
@@ -24,12 +24,21 @@ class AddCacheEntry : public QWidget, public Ui::AddCacheEntry
{
Q_OBJECT
public:
- AddCacheEntry(QWidget* p, const QStringList& completions);
+ AddCacheEntry(QWidget* p, const QStringList& varNames,
+ const QStringList& varTypes);
QString name() const;
QVariant value() const;
QString description() const;
QCMakeProperty::PropertyType type() const;
+ QString typeString() const;
+
+private slots:
+ void onCompletionActivated(const QString &text);
+
+private:
+ const QStringList& VarNames;
+ const QStringList& VarTypes;
};
#endif