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

#include "nowlisteningsettings.h"

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

class NowListeningSettingsHelper
{
  public:
    NowListeningSettingsHelper() : q(0) {}
    ~NowListeningSettingsHelper() { delete q; }
    NowListeningSettings *q;
};
K_GLOBAL_STATIC(NowListeningSettingsHelper, s_globalNowListeningSettings)
NowListeningSettings *NowListeningSettings::self()
{
  if (!s_globalNowListeningSettings->q) {
    new NowListeningSettings;
    s_globalNowListeningSettings->q->readConfig();
  }

  return s_globalNowListeningSettings->q;
}

NowListeningSettings::NowListeningSettings(  )
  : KConfigSkeleton( QLatin1String( "choqokrc" ) )
{
  Q_ASSERT(!s_globalNowListeningSettings->q);
  s_globalNowListeningSettings->q = this;
  setCurrentGroup( QLatin1String( "Now Listening Plugin" ) );

  mTemplateStringItem = new KConfigSkeleton::ItemString( currentGroup(), QLatin1String( "templateString" ), mTemplateString, QString::fromUtf8( "ᐅ %title% by %artist% from %album% [%player%]" ) );
  addItem( mTemplateStringItem, QLatin1String( "templateString" ) );
}

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

