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

#include "colortestconfig.h"

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

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

  return s_globalColorTestConfig()->q;
}

ColorTestConfig::ColorTestConfig( QObject *parent )
  : KConfigSkeleton()
{
  setParent(parent);
  Q_ASSERT(!s_globalColorTestConfig()->q);
  s_globalColorTestConfig()->q = this;
  KConfigCompilerSignallingItem::NotifyFunction notifyFunction = static_cast<KConfigCompilerSignallingItem::NotifyFunction>(&ColorTestConfig::itemChanged);

  setCurrentGroup( QStringLiteral( "General" ) );

  KConfigCompilerSignallingItem  *itemSomeSetting;
  KConfigSkeleton::ItemBool  *innerItemSomeSetting;
  innerItemSomeSetting = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "someSetting" ), mSomeSetting, true );
  itemSomeSetting = new KConfigCompilerSignallingItem(innerItemSomeSetting, this, notifyFunction, signalSomeSettingChanged);
  addItem( itemSomeSetting, QStringLiteral( "someSetting" ) );
}

bool ColorTestConfig::defaultSomeSettingValue_helper()
{

  return true;
}

ColorTestConfig::~ColorTestConfig()
{
  if (s_globalColorTestConfig.exists() && !s_globalColorTestConfig.isDestroyed()) {
    s_globalColorTestConfig()->q = nullptr;
  }
}


void ColorTestConfig::itemChanged(quint64 signalFlag) {

  switch (signalFlag) {
  case signalSomeSettingChanged:
    Q_EMIT someSettingChanged();
    break;
  }
}
