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

#include "dolphin_informationpanelsettings.h"

#include <kglobal.h>
#include <QtCore/QFile>

class InformationPanelSettingsHelper
{
  public:
    InformationPanelSettingsHelper() : q(0) {}
    ~InformationPanelSettingsHelper() { delete q; }
    InformationPanelSettings *q;
};
K_GLOBAL_STATIC(InformationPanelSettingsHelper, s_globalInformationPanelSettings)
InformationPanelSettings *InformationPanelSettings::self()
{
  if (!s_globalInformationPanelSettings->q) {
    new InformationPanelSettings;
    s_globalInformationPanelSettings->q->readConfig();
  }

  return s_globalInformationPanelSettings->q;
}

InformationPanelSettings::InformationPanelSettings(  )
  : KConfigSkeleton( QLatin1String( "dolphinrc" ) )
{
  Q_ASSERT(!s_globalInformationPanelSettings->q);
  s_globalInformationPanelSettings->q = this;
  setCurrentGroup( QLatin1String( "InformationPanel" ) );

  KConfigSkeleton::ItemBool  *itemPreviewsShown;
  itemPreviewsShown = new KConfigSkeleton::ItemBool( currentGroup(), QLatin1String( "previewsShown" ), mPreviewsShown, true );
  addItem( itemPreviewsShown, QLatin1String( "previewsShown" ) );
}

InformationPanelSettings::~InformationPanelSettings()
{
  if (!s_globalInformationPanelSettings.isDestroyed()) {
    s_globalInformationPanelSettings->q = 0;
  }
}

