00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef _PREFS_DIALOG_H_
00025 #define _PREFS_DIALOG_H_
00026
00027 #include "util/qvlcframe.hpp"
00028 #include "components/simple_preferences.hpp"
00029
00030 class PrefsTree;
00031 class SPrefsCatList;
00032 class AdvPrefsPanel;
00033 class SPrefsPanel;
00034 class QTreeWidgetItem;
00035 class QTreeWidget;
00036 class QHBoxLayout;
00037 class QVBoxLayout;
00038 class QGroupBox;
00039 class QRadioButton;
00040 class QWidget;
00041 class QCheckBox;
00042 class QLabel;
00043
00044 class PrefsDialog : public QVLCDialog
00045 {
00046 Q_OBJECT;
00047 public:
00048 static PrefsDialog * getInstance( intf_thread_t *p_intf )
00049 {
00050 if( !instance )
00051 instance = new PrefsDialog( (QWidget *)p_intf->p_sys->p_mi, p_intf );
00052 return instance;
00053 }
00054 virtual ~PrefsDialog() {};
00055 #if 0
00056
00057 void showModulePrefs( char* );
00058 #endif
00059
00060 private:
00061 PrefsDialog( QWidget *, intf_thread_t * );
00062 QGridLayout *main_layout;
00063
00064 void destroyPanels();
00065
00066 QWidget *main_panel;
00067 QHBoxLayout *main_panel_l;
00068
00069 AdvPrefsPanel *advanced_panel;
00070 SPrefsPanel *current_simple_panel;
00071 SPrefsPanel *simple_panels[SPrefsMax];
00072
00073 QWidget *tree_panel;
00074 QHBoxLayout *tree_panel_l;
00075
00076 SPrefsCatList *simple_tree;
00077 PrefsTree *advanced_tree;
00078
00079 QGroupBox *types;
00080 QRadioButton *small,*all;
00081
00082 static PrefsDialog *instance;
00083
00084 private slots:
00085 void setAdvanced();
00086 void setSmall();
00087
00088 void changeAdvPanel( QTreeWidgetItem * );
00089 void changeSimplePanel( int );
00090
00091 void save();
00092 void cancel();
00093 void reset();
00094 };
00095
00096 #endif