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

#include "workspaceoptions_kwinsettings.h"

WorkspaceOptionsKwinSettings::WorkspaceOptionsKwinSettings( QObject *parent )
  : KConfigSkeleton( QStringLiteral( "kwinrc" ) )
{
  setParent(parent);
  KConfigCompilerSignallingItem::NotifyFunction notifyFunction = static_cast<KConfigCompilerSignallingItem::NotifyFunction>(&WorkspaceOptionsKwinSettings::itemChanged);

  setCurrentGroup( QStringLiteral( "Input" ) );

  KConfigCompilerSignallingItem  *itemTabletMode;
  KConfigSkeleton::ItemString  *innerItemTabletMode;
  innerItemTabletMode = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "TabletMode" ), mTabletMode, QStringLiteral( "auto" ) );
  itemTabletMode = new KConfigCompilerSignallingItem(innerItemTabletMode, this, notifyFunction, signalTabletModeChanged);
  itemTabletMode->setWriteFlags(KConfigBase::Notify);
  addItem( itemTabletMode, QStringLiteral( "tabletMode" ) );

  setCurrentGroup( QStringLiteral( "Wayland" ) );

  KConfigCompilerSignallingItem  *itemPrimarySelection;
  KConfigSkeleton::ItemBool  *innerItemPrimarySelection;
  innerItemPrimarySelection = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "EnablePrimarySelection" ), mPrimarySelection, true );
  itemPrimarySelection = new KConfigCompilerSignallingItem(innerItemPrimarySelection, this, notifyFunction, signalPrimarySelectionChanged);
  itemPrimarySelection->setWriteFlags(KConfigBase::Notify);
  addItem( itemPrimarySelection, QStringLiteral( "primarySelection" ) );
}

QString WorkspaceOptionsKwinSettings::defaultTabletModeValue_helper() const
{

  return QStringLiteral( "auto" );
}

bool WorkspaceOptionsKwinSettings::defaultPrimarySelectionValue_helper() const
{

  return true;
}

WorkspaceOptionsKwinSettings::~WorkspaceOptionsKwinSettings()
{
}


void WorkspaceOptionsKwinSettings::itemChanged(quint64 flags) {

  if ( flags & signalTabletModeChanged ) {
    Q_EMIT tabletModeChanged();
  }
  if ( flags & signalPrimarySelectionChanged ) {
    Q_EMIT primarySelectionChanged();
  }
}

#include "workspaceoptions_kwinsettings.moc"

