kpilotConfig.h
00001 #ifndef _KPILOT_KPILOTCONFIG_H
00002 #define _KPILOT_KPILOTCONFIG_H
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033 #include <ksimpleconfig.h>
00034
00035 class KCmdLineArgs;
00036 class QLineEdit;
00037 class QComboBox;
00038 class QCheckBox;
00039
00040 class KPilotConfigSettings : public KSimpleConfig
00041 {
00042 public:
00043 KPilotConfigSettings(const QString &filename,bool readonly=false);
00044 virtual ~KPilotConfigSettings();
00045
00046
00047
00048
00049
00050
00051
00052
00053
00054
00055
00056
00057
00058
00059
00060
00061
00062
00063
00064
00065
00066 #define IntProperty(a) \
00067 int get##a() const; \
00068 void set##a(int); \
00069
00070 #define BoolProperty(a) \
00071 bool get##a() const; \
00072 void set##a(bool);
00073
00074 #define StringProperty(a) \
00075 QString get##a() const; \
00076 void set##a(const QString &);
00077
00078 IntProperty(Version)
00079 IntProperty(Debug)
00080
00081
00082 StringProperty(PilotDevice)
00083 IntProperty(PilotSpeed)
00084 StringProperty(Encoding)
00085 StringProperty(User)
00086 BoolProperty(StartDaemonAtLogin)
00087 BoolProperty(DockDaemon)
00088 BoolProperty(KillDaemonOnExit)
00089 BoolProperty(QuitAfterSync)
00090
00091
00092 IntProperty(SyncType)
00093 BoolProperty(FullSyncOnPCChange)
00094 IntProperty(ConflictResolution)
00095
00096
00097
00098
00099 BoolProperty(InternalEditors)
00100 BoolProperty(ShowSecrets)
00101
00102
00103 KPilotConfigSettings &setAddressGroup();
00104 IntProperty(AddressDisplayMode)
00105 BoolProperty(UseKeyField)
00106
00107
00108 StringProperty(BackupOnly)
00109 StringProperty(Skip)
00110
00111
00112
00113
00114 #undef StringProperty
00115 #undef BoolProperty
00116 #undef IntProperty
00117
00118
00119
00120
00121 KPilotConfigSettings &setConduitGroup();
00122
00123 QStringList getInstalledConduits();
00124 void setInstalledConduits(const QStringList &);
00125
00126 QStringList getDirtyDatabases();
00127 void setDirtyDatabases(const QStringList &);
00128 void addDirtyDatabase(QString db);
00129
00130 QStringList getAppBlockChangedDatabases();
00131 void setAppBlockChangedDatabases(const QStringList &);
00132 void addAppBlockChangedDatabase(QString db);
00133
00134 QStringList getFlagsChangedDatabases();
00135 void setFlagsChangedDatabases(const QStringList &);
00136 void addFlagsChangedDatabase(QString db);
00137
00138 KPilotConfigSettings &setDatabaseGroup();
00139 void setDatabaseConduit(const QString &database,const QString &conduit);
00140
00141 public:
00142
00143
00144
00145 void sync() { KSimpleConfig::sync(); } ;
00146 KPilotConfigSettings & resetGroup()
00147 { setGroup(QString::null); return *this; } ;
00148
00149 } ;
00150
00151 class KPilotConfig
00152 {
00153 public:
00165 static KPilotConfigSettings& getConfig();
00166
00171 static QString getDefaultDBPath();
00172
00173
00180 static const int ConfigurationVersion;
00181
00186 static int getConfigVersion(KConfig *);
00187 static int getConfigVersion(KConfig&);
00188
00194 static void updateConfigVersion();
00195
00202 static QString versionDetails(int fileversion, bool run);
00203 static void sorryVersionOutdated(int fileversion);
00204 static void interactiveUpdate();
00205
00210 static int getDebugLevel(KCmdLineArgs *p);
00211
00216 static const QFont& fixed() ;
00217 } ;
00218
00219
00220
00221 #endif
This file is part of the documentation for kpilot Library Version 3.2.1.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sat Mar 6 17:18:08 2004 by
doxygen 1.3.6-20040222 written by
Dimitri van Heesch, © 1997-2003