// This file is generated by tdeconfig_compiler from ktstatsplugin.kcfg.
// All changes you do to this file will be lost.

#include "statspluginsettings.h"

#include <kstaticdeleter.h>

StatsPluginSettings *StatsPluginSettings::mSelf = 0;
static KStaticDeleter<StatsPluginSettings> staticStatsPluginSettingsDeleter;

StatsPluginSettings *StatsPluginSettings::self()
{
  if ( !mSelf ) {
    staticStatsPluginSettingsDeleter.setObject( mSelf, new StatsPluginSettings() );
    mSelf->readConfig();
  }

  return mSelf;
}

StatsPluginSettings::StatsPluginSettings(  )
  : TDEConfigSkeleton( TQString::fromLatin1( "ktinfowidgetpluginrc" ) )
{
  mSelf = this;
  setCurrentGroup( TQString::fromLatin1( "general" ) );

  TDEConfigSkeleton::ItemUInt  *itemUpdateChartsEveryGuiUpdates;
  itemUpdateChartsEveryGuiUpdates = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "UpdateChartsEveryGuiUpdates" ), mUpdateChartsEveryGuiUpdates, 4 );
  addItem( itemUpdateChartsEveryGuiUpdates, TQString::fromLatin1( "UpdateChartsEveryGuiUpdates" ) );
  TDEConfigSkeleton::ItemUInt  *itemGatherDataEveryMs;
  itemGatherDataEveryMs = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "GatherDataEveryMs" ), mGatherDataEveryMs, 1000 );
  addItem( itemGatherDataEveryMs, TQString::fromLatin1( "GatherDataEveryMs" ) );
  TDEConfigSkeleton::ItemBool  *itemPeersSpeed;
  itemPeersSpeed = new TDEConfigSkeleton::ItemBool( currentGroup(), TQString::fromLatin1( "PeersSpeed" ), mPeersSpeed, true );
  addItem( itemPeersSpeed, TQString::fromLatin1( "PeersSpeed" ) );
  TDEConfigSkeleton::ItemUInt  *itemPeersSpeedDataIval;
  itemPeersSpeedDataIval = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "PeersSpeedDataIval" ), mPeersSpeedDataIval, 4 );
  addItem( itemPeersSpeedDataIval, TQString::fromLatin1( "PeersSpeedDataIval" ) );
  TDEConfigSkeleton::ItemBool  *itemDrawLeechersInSwarms;
  itemDrawLeechersInSwarms = new TDEConfigSkeleton::ItemBool( currentGroup(), TQString::fromLatin1( "DrawLeechersInSwarms" ), mDrawLeechersInSwarms, false );
  addItem( itemDrawLeechersInSwarms, TQString::fromLatin1( "DrawLeechersInSwarms" ) );
  TDEConfigSkeleton::ItemBool  *itemDrawSeedersInSwarms;
  itemDrawSeedersInSwarms = new TDEConfigSkeleton::ItemBool( currentGroup(), TQString::fromLatin1( "DrawSeedersInSwarms" ), mDrawSeedersInSwarms, false );
  addItem( itemDrawSeedersInSwarms, TQString::fromLatin1( "DrawSeedersInSwarms" ) );
  TDEConfigSkeleton::ItemUInt  *itemDownloadMeasurements;
  itemDownloadMeasurements = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "DownloadMeasurements" ), mDownloadMeasurements, 256 );
  addItem( itemDownloadMeasurements, TQString::fromLatin1( "DownloadMeasurements" ) );
  TDEConfigSkeleton::ItemUInt  *itemPeersSpeedMeasurements;
  itemPeersSpeedMeasurements = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "PeersSpeedMeasurements" ), mPeersSpeedMeasurements, 256 );
  addItem( itemPeersSpeedMeasurements, TQString::fromLatin1( "PeersSpeedMeasurements" ) );
  TDEConfigSkeleton::ItemUInt  *itemUploadMeasurements;
  itemUploadMeasurements = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "UploadMeasurements" ), mUploadMeasurements, 256 );
  addItem( itemUploadMeasurements, TQString::fromLatin1( "UploadMeasurements" ) );
  TDEConfigSkeleton::ItemUInt  *itemConnectionsMeasurements;
  itemConnectionsMeasurements = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "ConnectionsMeasurements" ), mConnectionsMeasurements, 512 );
  addItem( itemConnectionsMeasurements, TQString::fromLatin1( "ConnectionsMeasurements" ) );
  TDEConfigSkeleton::ItemUInt  *itemDHTMeasurements;
  itemDHTMeasurements = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "DHTMeasurements" ), mDHTMeasurements, 512 );
  addItem( itemDHTMeasurements, TQString::fromLatin1( "DHTMeasurements" ) );
  TDEConfigSkeleton::ItemUInt  *itemMaxSpdMode;
  itemMaxSpdMode = new TDEConfigSkeleton::ItemUInt( currentGroup(), TQString::fromLatin1( "MaxSpdMode" ), mMaxSpdMode, 1 );
  addItem( itemMaxSpdMode, TQString::fromLatin1( "MaxSpdMode" ) );
}

StatsPluginSettings::~StatsPluginSettings()
{
  if ( mSelf == this )
    staticStatsPluginSettingsDeleter.setObject( mSelf, 0, false );
}

