summaryrefslogtreecommitdiff
path: root/scripts/kconfig/qconf.h
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/kconfig/qconf.h')
-rw-r--r--scripts/kconfig/qconf.h177
1 files changed, 11 insertions, 166 deletions
diff --git a/scripts/kconfig/qconf.h b/scripts/kconfig/qconf.h
index 213990129e51..d025f29694c6 100644
--- a/scripts/kconfig/qconf.h
+++ b/scripts/kconfig/qconf.h
@@ -8,8 +8,6 @@
#include <qsettings.h>
class ConfigView;
-class ConfigList;
-class ConfigItem;
class ConfigLineEdit;
class ConfigMainWindow;
@@ -30,159 +28,6 @@ enum optionMode {
normalOpt = 0, allOpt, promptOpt
};
-class ConfigList : public Q3ListView {
- Q_OBJECT
- typedef class Q3ListView Parent;
-public:
- ConfigList(ConfigView* p, const char *name = 0);
- void reinit(void);
- ConfigView* parent(void) const
- {
- return (ConfigView*)Parent::parent();
- }
- ConfigItem* findConfigItem(struct menu *);
-
-protected:
- void keyPressEvent(QKeyEvent *e);
- void contentsMousePressEvent(QMouseEvent *e);
- void contentsMouseReleaseEvent(QMouseEvent *e);
- void contentsMouseMoveEvent(QMouseEvent *e);
- void contentsMouseDoubleClickEvent(QMouseEvent *e);
- void focusInEvent(QFocusEvent *e);
- void contextMenuEvent(QContextMenuEvent *e);
-
-public slots:
- void setRootMenu(struct menu *menu);
-
- void updateList(ConfigItem *item);
- void setValue(ConfigItem* item, tristate val);
- void changeValue(ConfigItem* item);
- void updateSelection(void);
- void saveSettings(void);
-signals:
- void menuChanged(struct menu *menu);
- void menuSelected(struct menu *menu);
- void parentSelected(void);
- void gotFocus(struct menu *);
-
-public:
- void updateListAll(void)
- {
- updateAll = true;
- updateList(NULL);
- updateAll = false;
- }
- ConfigList* listView()
- {
- return this;
- }
- ConfigItem* firstChild() const
- {
- return (ConfigItem *)Parent::firstChild();
- }
- int mapIdx(colIdx idx)
- {
- return colMap[idx];
- }
- void addColumn(colIdx idx, const QString& label)
- {
- colMap[idx] = Parent::addColumn(label);
- colRevMap[colMap[idx]] = idx;
- }
- void removeColumn(colIdx idx)
- {
- int col = colMap[idx];
- if (col >= 0) {
- Parent::removeColumn(col);
- colRevMap[col] = colMap[idx] = -1;
- }
- }
- void setAllOpen(bool open);
- void setParentMenu(void);
-
- bool menuSkip(struct menu *);
-
- template <class P>
- void updateMenuList(P*, struct menu*);
-
- bool updateAll;
-
- QPixmap symbolYesPix, symbolModPix, symbolNoPix;
- QPixmap choiceYesPix, choiceNoPix;
- QPixmap menuPix, menuInvPix, menuBackPix, voidPix;
-
- bool showName, showRange, showData;
- enum listMode mode;
- enum optionMode optMode;
- struct menu *rootEntry;
- QColorGroup disabledColorGroup;
- QColorGroup inactivedColorGroup;
- QMenu* headerPopup;
-
-private:
- int colMap[colNr];
- int colRevMap[colNr];
-};
-
-class ConfigItem : public Q3ListViewItem {
- typedef class Q3ListViewItem Parent;
-public:
- ConfigItem(Q3ListView *parent, ConfigItem *after, struct menu *m, bool v)
- : Parent(parent, after), menu(m), visible(v), goParent(false)
- {
- init();
- }
- ConfigItem(ConfigItem *parent, ConfigItem *after, struct menu *m, bool v)
- : Parent(parent, after), menu(m), visible(v), goParent(false)
- {
- init();
- }
- ConfigItem(Q3ListView *parent, ConfigItem *after, bool v)
- : Parent(parent, after), menu(0), visible(v), goParent(true)
- {
- init();
- }
- ~ConfigItem(void);
- void init(void);
- void okRename(int col);
- void updateMenu(void);
- void testUpdateMenu(bool v);
- ConfigList* listView() const
- {
- return (ConfigList*)Parent::listView();
- }
- ConfigItem* firstChild() const
- {
- return (ConfigItem *)Parent::firstChild();
- }
- ConfigItem* nextSibling() const
- {
- return (ConfigItem *)Parent::nextSibling();
- }
- void setText(colIdx idx, const QString& text)
- {
- Parent::setText(listView()->mapIdx(idx), text);
- }
- QString text(colIdx idx) const
- {
- return Parent::text(listView()->mapIdx(idx));
- }
- void setPixmap(colIdx idx, const QPixmap& pm)
- {
- Parent::setPixmap(listView()->mapIdx(idx), pm);
- }
- const QPixmap* pixmap(colIdx idx) const
- {
- return Parent::pixmap(listView()->mapIdx(idx));
- }
- void paintCell(QPainter* p, const QColorGroup& cg, int column, int width, int align);
-
- ConfigItem* nextItem;
- struct menu *menu;
- bool visible;
- bool goParent;
-};
-
class ConfigLineEdit : public QLineEdit {
Q_OBJECT
typedef class QLineEdit Parent;
@@ -192,11 +37,11 @@ public:
{
return (ConfigView*)Parent::parent();
}
- void show(ConfigItem *i);
+ void show(Q3ListViewItem *i);
void keyPressEvent(QKeyEvent *e);
public:
- ConfigItem *item;
+ Q3ListViewItem *item;
};
class ConfigView : public QWidget {
@@ -205,12 +50,12 @@ class ConfigView : public QWidget {
public:
ConfigView(QWidget* parent, const char *name = 0);
~ConfigView(void);
- static void updateList(ConfigItem* item);
+ static void updateList(Q3ListViewItem* item);
static void updateListAll(void);
- bool showName(void) const { return list->showName; }
- bool showRange(void) const { return list->showRange; }
- bool showData(void) const { return list->showData; }
+ bool showName(void) const { return false; } // TODO: Implement me.
+ bool showRange(void) const { return false; } // TODO: Implement me.
+ bool showData(void) const { return false; } // TODO: Implement me.
public slots:
void setShowName(bool);
void setShowRange(bool);
@@ -221,7 +66,7 @@ signals:
void showRangeChanged(bool);
void showDataChanged(bool);
public:
- ConfigList* list;
+ Q3ListView* list;
ConfigLineEdit* lineEdit;
static ConfigView* viewList;
@@ -310,15 +155,15 @@ protected:
ConfigSearchWindow *searchWindow;
ConfigView *menuView;
- ConfigList *menuList;
+ Q3ListView *menuList;
ConfigView *configView;
- ConfigList *configList;
+ Q3ListView *configList;
ConfigInfoView *helpText;
QToolBar *toolBar;
QAction *backAction;
QAction *singleViewAction;
QAction *splitViewAction;
QAction *fullViewAction;
- QSplitter* split1;
- QSplitter* split2;
+ QSplitter *split1;
+ QSplitter *split2;
};