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

#include "magiclampconfig.h"

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

using namespace KWin;

namespace KWin {

class MagicLampConfigHelper
{
  public:
    MagicLampConfigHelper() : q(0) {}
    ~MagicLampConfigHelper() { delete q; }
    MagicLampConfig *q;
};
}

K_GLOBAL_STATIC(MagicLampConfigHelper, s_globalMagicLampConfig)
MagicLampConfig *MagicLampConfig::self()
{
  if (!s_globalMagicLampConfig->q) {
    new MagicLampConfig;
    s_globalMagicLampConfig->q->readConfig();
  }

  return s_globalMagicLampConfig->q;
}

MagicLampConfig::MagicLampConfig(  )
  : KConfigSkeleton( QLatin1String( "kwinrc" ) )
{
  Q_ASSERT(!s_globalMagicLampConfig->q);
  s_globalMagicLampConfig->q = this;
  setCurrentGroup( QLatin1String( "Effect-MagicLamp" ) );

  KConfigSkeleton::ItemInt  *itemAnimationDuration;
  itemAnimationDuration = new KConfigSkeleton::ItemInt( currentGroup(), QLatin1String( "AnimationDuration" ), mAnimationDuration, 0 );
  addItem( itemAnimationDuration, QLatin1String( "AnimationDuration" ) );
}

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

