koprefsdialog.h
00001 /* 00002 This file is part of KOrganizer. 00003 Copyright (c) 2000,2001,2002,2003 Cornelius Schumacher <schumacher@kde.org> 00004 Copyright (c) 2003-2004 Reinhold Kainhofer <reinhold@kainhofer.com> 00005 00006 This program is free software; you can redistribute it and/or modify 00007 it under the terms of the GNU General Public License as published by 00008 the Free Software Foundation; either version 2 of the License, or 00009 (at your option) any later version. 00010 00011 This program is distributed in the hope that it will be useful, 00012 but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 GNU General Public License for more details. 00015 00016 You should have received a copy of the GNU General Public License 00017 along with this program; if not, write to the Free Software 00018 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 00019 00020 As a special exception, permission is given to link this program 00021 with any edition of TQt, and distribute the resulting executable, 00022 without including the source code for TQt in the source distribution. 00023 */ 00024 #ifndef KOPREFSDIALOG_H 00025 #define KOPREFSDIALOG_H 00026 00027 #include <libtdepim/kprefsdialog.h> 00028 #include <libtdepim/kcmdesignerfields.h> 00029 00030 #include <tqdict.h> 00031 00032 class TQLineEdit; 00033 class TQLabel; 00034 class TQSpinBox; 00035 class TQComboBox; 00036 class KColorButton; 00037 class KPushButton; 00038 class TQColor; 00039 class TQListView; 00040 00041 class KDE_EXPORT KOPrefsDialogMain : public KPrefsModule 00042 { 00043 Q_OBJECT 00044 00045 public: 00046 KOPrefsDialogMain( TQWidget *parent, const char *name ); 00047 00048 protected slots: 00049 void toggleEmailSettings( bool on ); 00050 private: 00051 TQWidget *mUserEmailSettings; 00052 }; 00053 00054 class KDE_EXPORT KOPrefsDialogColors : public KPrefsModule 00055 { 00056 Q_OBJECT 00057 00058 public: 00059 KOPrefsDialogColors( TQWidget *parent, const char *name ); 00060 00061 protected: 00062 void usrWriteConfig(); 00063 void usrReadConfig(); 00064 00065 protected slots: 00066 void updateCategories(); 00067 void setCategoryColor(); 00068 void updateCategoryColor(); 00069 00070 void updateResources(); 00071 void setResourceColor(); 00072 void updateResourceColor(); 00073 private: 00074 TQComboBox *mCategoryCombo; 00075 KColorButton *mCategoryButton; 00076 TQDict<TQColor> mCategoryDict; 00077 00078 TQComboBox *mResourceCombo; 00079 KColorButton *mResourceButton; 00080 TQDict<TQColor> mResourceDict; 00081 //For translation Identifier <->idx in Combo 00082 TQStringList mResourceIdentifier; 00083 }; 00084 00085 class KDE_EXPORT KOPrefsDialogGroupScheduling : public KPrefsModule 00086 { 00087 Q_OBJECT 00088 00089 public: 00090 KOPrefsDialogGroupScheduling( TQWidget *parent, const char *name ); 00091 00092 protected: 00093 void usrReadConfig(); 00094 void usrWriteConfig(); 00095 00096 protected slots: 00097 void addItem(); 00098 void removeItem(); 00099 void updateItem(); 00100 void updateInput(); 00101 00102 private: 00103 TQListView *mAMails; 00104 TQLineEdit *aEmailsEdit; 00105 }; 00106 00107 class KOGroupwarePrefsPage; 00108 00109 class KDE_EXPORT KOPrefsDialogGroupwareScheduling : public KPrefsModule 00110 { 00111 Q_OBJECT 00112 00113 public: 00114 KOPrefsDialogGroupwareScheduling( TQWidget *parent, const char *name ); 00115 00116 protected: 00117 void usrReadConfig(); 00118 void usrWriteConfig(); 00119 00120 private: 00121 KOGroupwarePrefsPage* mGroupwarePage; 00122 }; 00123 00124 class KDE_EXPORT KOPrefsDialogPlugins : public KPrefsModule 00125 { 00126 Q_OBJECT 00127 00128 public: 00129 KOPrefsDialogPlugins( TQWidget *parent, const char *name ); 00130 00131 protected slots: 00132 void usrReadConfig(); 00133 void usrWriteConfig(); 00134 void configure(); 00135 void selectionChanged( TQListViewItem* ); 00136 00137 private: 00138 void buildList(); 00139 TQListView *mListView; 00140 TQLabel *mDescription; 00141 KPushButton *mConfigureButton; 00142 }; 00143 00144 class KDE_EXPORT KOPrefsDesignerFields : public KPIM::KCMDesignerFields 00145 { 00146 public: 00147 KOPrefsDesignerFields( TQWidget *parent = 0, const char *name = 0 ); 00148 00149 protected: 00150 TQString localUiDir(); 00151 TQString uiPath(); 00152 void writeActivePages( const TQStringList & ); 00153 TQStringList readActivePages(); 00154 TQString applicationName(); 00155 }; 00156 00157 #endif