cosmetix
[jrugr.git] / src / xkbconf.h
blobee154ce30e10b9073f3ab506ae508deef7519ad5
1 ////////////////////////////////////////
2 // File : xkbconf.h //
3 // Written by: disels@gmail.com //
4 // Copyright : GPL //
5 ////////////////////////////////////////
6 #ifndef XKBCONF_H
7 #define XKBCONF_H
9 #include "defs.h"
10 #include "x11tools.h"
11 #include "datamodels.h"
12 #include "ui_kswconfig.h"
15 class QXKBconf : public QDialog {
16 Q_OBJECT
18 public:
19 QXKBconf (QWidget *parent=0);
20 ~QXKBconf ();
22 void getHotKeys (XEvent *event);
23 void clearHotKeys ();
25 protected:
26 void closeEvent (QCloseEvent *event);
28 signals:
29 void saveConfig ();
31 public slots:
32 void addLayout ();
33 void delLayout ();
34 void srcClick (QModelIndex index);
35 void dstClick ();
36 void comboModelCh (int index);
37 void comboVariantCh (int index);
38 void statSelect (bool check);
39 void apply ();
40 void setFlagUse ();
41 void setSinglShow ();
42 void layoutUp ();
43 void layoutDown ();
44 void updateOptionsCommand ();
45 void xkbOptionsChanged (const QModelIndex &topLeft, const QModelIndex &bottomRight);
46 void xkbShortcutPressed ();
47 void xkbShortcut3dPressed ();
48 void statSwitching (bool chek);
50 public:
51 Ui_Form xkb_conf;
53 private:
54 bool load_rules ();
55 void setCmdLine ();
56 bool setStat ();
57 void initXKBTab ();
58 int getSelectedDstLayout ();
60 private:
61 QString theme;
62 QStringList listModels;
63 RulesInfo *curRule;
64 SrcLayoutModel *srcLayoutModel;
65 DstLayoutModel *dstLayoutModel;
66 XkbOptionsModel *xkbOptionsModel;
67 XKBConf *xkbConf;
68 QList<XkbVariant> variants;
69 QString ico_path;
70 QString key;
71 QString mods;
72 QString hot_keys;
76 #endif