kpilot/kpilot

KPilotConfig Class Reference

List of all members.

Detailed Description

Definition at line 39 of file kpilotConfig.h.


Public Types

enum  RunMode {
  Cancel = 0, Normal, ConfigureKPilot, ConfigureConduits,
  ConfigureAndContinue, WizardAndContinue
}

Static Public Member Functions

static QString getDefaultDBPath ()
static void addDirtyDatabase (QString db)
static void addAppBlockChangedDatabase (QString db)
static void addFlagsChangedDatabase (QString db)
static int getConfigVersion ()
static void updateConfigVersion ()
static QString versionDetails (int fileversion, bool run)
static void sorryVersionOutdated (int fileversion)
static RunMode interactiveUpdate ()
static int getDebugLevel (KCmdLineArgs *p)
static const QFont & fixed ()
static void sync ()

Static Public Attributes

static const uint ConfigurationVersion

Member Function Documentation

QString KPilotConfig::getDefaultDBPath (  )  [static]

Returns:
QString of default path for the BackupDB files are located

Definition at line 87 of file kpilotConfig.cc.

int KPilotConfig::getConfigVersion (  )  [static]

Reads the configuration version from a configuration file.

TODO: Make this use the *standard* location.

Definition at line 59 of file kpilotConfig.cc.

void KPilotConfig::updateConfigVersion (  )  [static]

Write the current configuration version to the standard location.

Only call this after the KApplication object is created, or crashes will result.

Definition at line 81 of file kpilotConfig.cc.

QString KPilotConfig::versionDetails ( int  fileversion,
bool  run 
) [static]

Warn the user that the config file is outdated.

versionDetails() returns a descriptive string. Pass in the actual version of the config file. Set run to true to add an admonition to run kpilot in config mode to fix this. sorryVersionOutdated() uses KMessageBox to display it.

Definition at line 160 of file kpilotConfig.cc.

KPilotConfig::RunMode KPilotConfig::interactiveUpdate (  )  [static]

Update the config file as best we can, and inform the user.

Returns a suggested run mode if it's ok (ie. update finished, or file was already up-to-date) and Cancel if the user cancels. If the user cancels, it's probably best to _not_ continue with anything, since the config is bogus.

The suggested run mode might be anything - usually normal, but might return ConfigureAndContinue as well.

This function can call functions to update from different versions to current; these are static in kpilotConfig.cc.

Definition at line 294 of file kpilotConfig.cc.

int KPilotConfig::getDebugLevel ( KCmdLineArgs *  p  )  [static]

Deal with --debug options.

resulting debug level

Definition at line 97 of file kpilotConfig.cc.

const QFont & KPilotConfig::fixed (  )  [static]

Returns the user's preference for the system-wide fixed font.

Definition at line 114 of file kpilotConfig.cc.


Member Data Documentation

This number can be changed every time a new KPilot version is released that absolutely requires the user to take a look at the configuration of KPilot.

Definition at line 70 of file kpilotConfig.h.


The documentation for this class was generated from the following files:
KDE Home | KDE Accessibility Home | Description of Access Keys