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

#include "kcmaccessibilitykeyboardfilters.h"

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

  setCurrentGroup( QStringLiteral( "Keyboard" ) );

  KConfigCompilerSignallingItem  *itemSlowKeys;
  KConfigSkeleton::ItemBool  *innerItemSlowKeys;
  innerItemSlowKeys = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SlowKeys" ), mSlowKeys, false );
  itemSlowKeys = new KConfigCompilerSignallingItem(innerItemSlowKeys, this, notifyFunction, signalSlowKeysChanged);
  itemSlowKeys->setWriteFlags(KConfigBase::Notify);
  addItem( itemSlowKeys, QStringLiteral( "SlowKeys" ) );
  KConfigCompilerSignallingItem  *itemSlowKeysDelay;
  KConfigSkeleton::ItemInt  *innerItemSlowKeysDelay;
  innerItemSlowKeysDelay = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "SlowKeysDelay" ), mSlowKeysDelay, 500 );
  itemSlowKeysDelay = new KConfigCompilerSignallingItem(innerItemSlowKeysDelay, this, notifyFunction, signalSlowKeysDelayChanged);
  itemSlowKeysDelay->setWriteFlags(KConfigBase::Notify);
  addItem( itemSlowKeysDelay, QStringLiteral( "SlowKeysDelay" ) );
  KConfigCompilerSignallingItem  *itemSlowKeysPressBeep;
  KConfigSkeleton::ItemBool  *innerItemSlowKeysPressBeep;
  innerItemSlowKeysPressBeep = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SlowKeysPressBeep" ), mSlowKeysPressBeep, false );
  itemSlowKeysPressBeep = new KConfigCompilerSignallingItem(innerItemSlowKeysPressBeep, this, notifyFunction, signalSlowKeysPressBeepChanged);
  itemSlowKeysPressBeep->setWriteFlags(KConfigBase::Notify);
  addItem( itemSlowKeysPressBeep, QStringLiteral( "SlowKeysPressBeep" ) );
  KConfigCompilerSignallingItem  *itemSlowKeysAcceptBeep;
  KConfigSkeleton::ItemBool  *innerItemSlowKeysAcceptBeep;
  innerItemSlowKeysAcceptBeep = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SlowKeysAcceptBeep" ), mSlowKeysAcceptBeep, false );
  itemSlowKeysAcceptBeep = new KConfigCompilerSignallingItem(innerItemSlowKeysAcceptBeep, this, notifyFunction, signalSlowKeysAcceptBeepChanged);
  itemSlowKeysAcceptBeep->setWriteFlags(KConfigBase::Notify);
  addItem( itemSlowKeysAcceptBeep, QStringLiteral( "SlowKeysAcceptBeep" ) );
  KConfigCompilerSignallingItem  *itemSlowKeysRejectBeep;
  KConfigSkeleton::ItemBool  *innerItemSlowKeysRejectBeep;
  innerItemSlowKeysRejectBeep = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "SlowKeysRejectBeep" ), mSlowKeysRejectBeep, false );
  itemSlowKeysRejectBeep = new KConfigCompilerSignallingItem(innerItemSlowKeysRejectBeep, this, notifyFunction, signalSlowKeysRejectBeepChanged);
  itemSlowKeysRejectBeep->setWriteFlags(KConfigBase::Notify);
  addItem( itemSlowKeysRejectBeep, QStringLiteral( "SlowKeysRejectBeep" ) );
  KConfigCompilerSignallingItem  *itemBounceKeys;
  KConfigSkeleton::ItemBool  *innerItemBounceKeys;
  innerItemBounceKeys = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "BounceKeys" ), mBounceKeys, false );
  itemBounceKeys = new KConfigCompilerSignallingItem(innerItemBounceKeys, this, notifyFunction, signalBounceKeysChanged);
  itemBounceKeys->setWriteFlags(KConfigBase::Notify);
  addItem( itemBounceKeys, QStringLiteral( "BounceKeys" ) );
  KConfigCompilerSignallingItem  *itemBounceKeysDelay;
  KConfigSkeleton::ItemInt  *innerItemBounceKeysDelay;
  innerItemBounceKeysDelay = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "BounceKeysDelay" ), mBounceKeysDelay, 500 );
  itemBounceKeysDelay = new KConfigCompilerSignallingItem(innerItemBounceKeysDelay, this, notifyFunction, signalBounceKeysDelayChanged);
  itemBounceKeysDelay->setWriteFlags(KConfigBase::Notify);
  addItem( itemBounceKeysDelay, QStringLiteral( "BounceKeysDelay" ) );
  KConfigCompilerSignallingItem  *itemBounceKeysRejectBeep;
  KConfigSkeleton::ItemBool  *innerItemBounceKeysRejectBeep;
  innerItemBounceKeysRejectBeep = new KConfigSkeleton::ItemBool( currentGroup(), QStringLiteral( "BounceKeysRejectBeep" ), mBounceKeysRejectBeep, false );
  itemBounceKeysRejectBeep = new KConfigCompilerSignallingItem(innerItemBounceKeysRejectBeep, this, notifyFunction, signalBounceKeysRejectBeepChanged);
  itemBounceKeysRejectBeep->setWriteFlags(KConfigBase::Notify);
  addItem( itemBounceKeysRejectBeep, QStringLiteral( "BounceKeysRejectBeep" ) );
}

bool KeyboardFiltersSettings::defaultSlowKeysValue_helper() const
{

  return false;
}

int KeyboardFiltersSettings::defaultSlowKeysDelayValue_helper() const
{

  return 500;
}

bool KeyboardFiltersSettings::defaultSlowKeysPressBeepValue_helper() const
{

  return false;
}

bool KeyboardFiltersSettings::defaultSlowKeysAcceptBeepValue_helper() const
{

  return false;
}

bool KeyboardFiltersSettings::defaultSlowKeysRejectBeepValue_helper() const
{

  return false;
}

bool KeyboardFiltersSettings::defaultBounceKeysValue_helper() const
{

  return false;
}

int KeyboardFiltersSettings::defaultBounceKeysDelayValue_helper() const
{

  return 500;
}

bool KeyboardFiltersSettings::defaultBounceKeysRejectBeepValue_helper() const
{

  return false;
}

KeyboardFiltersSettings::~KeyboardFiltersSettings()
{
}


void KeyboardFiltersSettings::itemChanged(quint64 signalFlag) {

  switch (signalFlag) {
  case signalSlowKeysChanged:
    Q_EMIT SlowKeysChanged();
    break;
  case signalSlowKeysDelayChanged:
    Q_EMIT SlowKeysDelayChanged();
    break;
  case signalSlowKeysPressBeepChanged:
    Q_EMIT SlowKeysPressBeepChanged();
    break;
  case signalSlowKeysAcceptBeepChanged:
    Q_EMIT SlowKeysAcceptBeepChanged();
    break;
  case signalSlowKeysRejectBeepChanged:
    Q_EMIT SlowKeysRejectBeepChanged();
    break;
  case signalBounceKeysChanged:
    Q_EMIT BounceKeysChanged();
    break;
  case signalBounceKeysDelayChanged:
    Q_EMIT BounceKeysDelayChanged();
    break;
  case signalBounceKeysRejectBeepChanged:
    Q_EMIT BounceKeysRejectBeepChanged();
    break;
  }
}
