]> git.sesse.net Git - vlc/blobdiff - modules/gui/qt4/components/preferences_widgets.hpp
Qt4 - Hotkeys, correct some unicode problem and change the default behaviour.
[vlc] / modules / gui / qt4 / components / preferences_widgets.hpp
index 836e66f7bca226beaadb742da0b28925db01ff7a..1b9ff8173e7ed8e97f677c275598cc63b3c28c50 100644 (file)
@@ -50,6 +50,7 @@ class QTreeWidget;
 class QTreeWidgetItem;
 class QGroupBox;
 class QGridLayout;
+class QDialogButtonBox;
 
 class ConfigControl : public QObject
 {
@@ -85,8 +86,11 @@ protected:
     QString _name;
     QWidget *widget;
     bool _advanced;
+#if 0
+/* You shouldn't use that now..*/
 signals:
     void Updated();
+#endif
 };
 
 /*******************************************************
@@ -360,6 +364,7 @@ private:
 
 class StringListConfigControl : public VStringConfigControl
 {
+    Q_OBJECT;
 public:
     StringListConfigControl( vlc_object_t *, module_config_t *, QWidget *,
                              bool, QGridLayout*, int& );
@@ -373,7 +378,14 @@ private:
     void finish( bool );
     QLabel *label;
     QComboBox *combo;
+private slots:
+    void actionRequested( int );
+
 };
+
+void setfillVLCConfigCombo(const char *configname, intf_thread_t *p_intf,
+                        QComboBox *combo, QWidget *parent = 0 );
+
 #if 0
 struct ModuleCheckBox {
     QCheckBox *checkbox;
@@ -401,7 +413,7 @@ private slot:
 class KeyInputDialog : public QDialog
 {
 public:
-    KeyInputDialog( QList<module_config_t *> &, const char * );
+    KeyInputDialog( QList<module_config_t *> &, const char *, QWidget * );
     int keyValue;
     bool conflicts;
 private:
@@ -412,6 +424,16 @@ private:
     QLabel *warning;
     const char * keyToChange;
     QList<module_config_t*> values;
+    QDialogButtonBox *buttonBox;
+};
+
+class KeyShortcutEdit: public QLineEdit
+{
+    Q_OBJECT
+private:
+    virtual void mousePressEvent( QMouseEvent *event );
+signals:
+    void pressed();
 };
 
 class KeySelectorControl : public ConfigControl
@@ -429,9 +451,12 @@ private:
     void finish();
     QLabel *label;
     QTreeWidget *table;
+    KeyShortcutEdit *shortcutValue;
     QList<module_config_t *> values;
 private slots:
-    void selectKey( QTreeWidgetItem *);
+    void setTheKey();
+    void selectKey( QTreeWidgetItem * = NULL );
+    void select1Key( QTreeWidgetItem *);
 };
 
 #endif