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

#include "blurconfig.h"

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

using namespace KWin;

namespace KWin {

class BlurConfigHelper
{
  public:
    BlurConfigHelper() : q(0) {}
    ~BlurConfigHelper() { delete q; }
    BlurConfig *q;
};
}

K_GLOBAL_STATIC(BlurConfigHelper, s_globalBlurConfig)
BlurConfig *BlurConfig::self()
{
  if (!s_globalBlurConfig->q) {
    new BlurConfig;
    s_globalBlurConfig->q->readConfig();
  }

  return s_globalBlurConfig->q;
}

BlurConfig::BlurConfig(  )
  : KConfigSkeleton( QLatin1String( "kwinrc" ) )
{
  Q_ASSERT(!s_globalBlurConfig->q);
  s_globalBlurConfig->q = this;
  setCurrentGroup( QLatin1String( "Effect-Blur" ) );

  KConfigSkeleton::ItemInt  *itemBlurRadius;
  itemBlurRadius = new KConfigSkeleton::ItemInt( currentGroup(), QLatin1String( "BlurRadius" ), mBlurRadius, 12 );
  addItem( itemBlurRadius, QLatin1String( "BlurRadius" ) );
  KConfigSkeleton::ItemBool  *itemCacheTexture;
  itemCacheTexture = new KConfigSkeleton::ItemBool( currentGroup(), QLatin1String( "CacheTexture" ), mCacheTexture, true );
  addItem( itemCacheTexture, QLatin1String( "CacheTexture" ) );
}

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

