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

#include "cmakebuilderconfig.h"

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

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

  return s_globalCMakeBuilderSettings()->q;
}

CMakeBuilderSettings::CMakeBuilderSettings( )
  : KConfigSkeleton( QStringLiteral( "kdeveloprc" ) )
{
  Q_ASSERT(!s_globalCMakeBuilderSettings()->q);
  s_globalCMakeBuilderSettings()->q = this;
  setCurrentGroup( QStringLiteral( "CMakeBuilder" ) );

  mCmakeExecutableItem = new KConfigSkeleton::ItemUrl( currentGroup(), QStringLiteral( "cmakeExe" ), mCmakeExecutable, QUrl::fromLocalFile(CMake::findExecutable()) );
  mCmakeExecutableItem->setLabel( QCoreApplication::translate("CMakeBuilderSettings", "cmakeExe") );
  mCmakeExecutableItem->setWhatsThis( QCoreApplication::translate("CMakeBuilderSettings", "The path to the default CMake executable.") );
  addItem( mCmakeExecutableItem, QStringLiteral( "cmakeExecutable" ) );
  mGeneratorItem = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "generator" ), mGenerator, 0 );
  mGeneratorItem->setLabel( QCoreApplication::translate("CMakeBuilderSettings", "generator") );
  addItem( mGeneratorItem, QStringLiteral( "generator" ) );
}

CMakeBuilderSettings::~CMakeBuilderSettings()
{
  s_globalCMakeBuilderSettings()->q = nullptr;
}

