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

#include "infowidgetpluginsettings.h"

#include <qglobal.h>
#include <QFile>

class InfoWidgetPluginSettingsHelper
{
  public:
    InfoWidgetPluginSettingsHelper() : q(nullptr) {}
    ~InfoWidgetPluginSettingsHelper() { delete q; }
    InfoWidgetPluginSettingsHelper(const InfoWidgetPluginSettingsHelper&) = delete;
    InfoWidgetPluginSettingsHelper& operator=(const InfoWidgetPluginSettingsHelper&) = delete;
    InfoWidgetPluginSettings *q;
};
Q_GLOBAL_STATIC(InfoWidgetPluginSettingsHelper, s_globalInfoWidgetPluginSettings)
InfoWidgetPluginSettings *InfoWidgetPluginSettings::self()
{
  if (!s_globalInfoWidgetPluginSettings()->q) {
    new InfoWidgetPluginSettings;
    s_globalInfoWidgetPluginSettings()->q->read();
  }

  return s_globalInfoWidgetPluginSettings()->q;
}

InfoWidgetPluginSettings::InfoWidgetPluginSettings( )
  : KConfigSkeleton( QStringLiteral( "ktorrent_infowidgetrc" ) )
{
  Q_ASSERT(!s_globalInfoWidgetPluginSettings()->q);
  s_globalInfoWidgetPluginSettings()->q = this;
  setCurrentGroup( QStringLiteral( "general" ) );

  KConfigSkeleton::ItemBool  *itemShowPeerView;
  itemShowPeerView = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "showPeerView" ), mShowPeerView, true );
  addItem( itemShowPeerView, QStringLiteral( "showPeerView" ) );
  KConfigSkeleton::ItemBool  *itemShowChunkView;
  itemShowChunkView = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "showChunkView" ), mShowChunkView, true );
  addItem( itemShowChunkView, QStringLiteral( "showChunkView" ) );
  KConfigSkeleton::ItemBool  *itemShowTrackersView;
  itemShowTrackersView = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "showTrackersView" ), mShowTrackersView, true );
  addItem( itemShowTrackersView, QStringLiteral( "showTrackersView" ) );
  KConfigSkeleton::ItemBool  *itemShowWebSeedsTab;
  itemShowWebSeedsTab = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "showWebSeedsTab" ), mShowWebSeedsTab, true );
  addItem( itemShowWebSeedsTab, QStringLiteral( "showWebSeedsTab" ) );
  KConfigSkeleton::ItemColor  *itemFirstColor;
  itemFirstColor = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "firstColor" ), mFirstColor, QColor() );
  addItem( itemFirstColor, QStringLiteral( "firstColor" ) );
  KConfigSkeleton::ItemColor  *itemLastColor;
  itemLastColor = new KConfigSkeleton::ItemColor( currentGroup(), QStringLiteral( "lastColor" ), mLastColor, QColor() );
  addItem( itemLastColor, QStringLiteral( "lastColor" ) );
}

InfoWidgetPluginSettings::~InfoWidgetPluginSettings()
{
  s_globalInfoWidgetPluginSettings()->q = nullptr;
}

