kconfigdialog.h
00001 
00002 
00003 
00004 
00005 
00006 
00007 
00008 
00009 
00010 
00011 
00012 
00013 
00014 
00015 
00016 
00017 
00018 
00019 
00020 
00021 #ifndef KCONFIGDIALOG_H
00022 #define KCONFIGDIALOG_H
00023 
00024 class KConfig;
00025 class KConfigSkeleton;
00026 #include <kdialogbase.h>
00027 #include <qasciidict.h>
00028 
00067 class KConfigDialog : public KDialogBase {
00068 Q_OBJECT
00069 
00070 signals:
00074   void widgetModified();
00075 
00080   void settingsChanged();
00081 
00090   void settingsChanged(const char *dialogName);
00091 
00092 public:
00114   KConfigDialog( QWidget *parent, const char *name,
00115                  KConfigSkeleton *config,
00116          KDialogBase::DialogType dialogType = KDialogBase::IconList,
00117          int dialogButtons = KDialogBase::Default | KDialogBase::Ok | KDialogBase::Apply | KDialogBase::Cancel | KDialogBase::Help,
00118          KDialogBase::ButtonCode defaultButton = Ok,
00119          bool modal=false );
00120 
00126   ~KConfigDialog();
00127 
00142   void addPage( QWidget *page, const QString &itemName,
00143                           const QString &pixmapName,
00144                   const QString &header=QString::null,
00145                   bool manage=true);
00146 
00153   static KConfigDialog* exists( const char* name );
00154 
00161   static bool showDialog( const char* name );
00162 
00166   virtual void show();
00167 
00168 protected slots:
00175   virtual void updateSettings();
00176 
00184   virtual void updateWidgets();
00185 
00192   virtual void updateWidgetsDefault();
00193 
00194 protected:
00195 
00201   virtual bool hasChanged() { return false; }
00202 
00207   virtual bool isDefault() { return true; }
00208   
00209 
00210 protected slots:
00214   void updateButtons();
00215 
00219   void settingsChangedSlot();
00220 
00221 private:
00225   static QAsciiDict<KConfigDialog> openDialogs;
00226 
00227   class KConfigDialogPrivate;
00231   KConfigDialogPrivate *d;
00232 };
00233 
00234 #endif //KCONFIGDIALOG_H
00235 
 
This file is part of the documentation for kdeui Library Version 3.2.0.