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

#include "easyeffects_db_level_meter.h"

DbLevelMeter::DbLevelMeter( const QString & masterGroup, const QString & instanceIndex )
  : KConfigBaseEE( QStringLiteral( "easyeffects/db/levelmeterrc" ) )
  , mParammasterGroup(masterGroup)
  , mParaminstanceIndex(instanceIndex)
{
  KConfigCompilerSignallingItem::NotifyFunction notifyFunction = static_cast<KConfigCompilerSignallingItem::NotifyFunction>(&DbLevelMeter::itemChanged);

  KConfigGroup cgmasterGroup(this->config(), QStringLiteral( "%1" ).arg( mParammasterGroup ));
  KConfigGroup cgLevelMeterinstanceIndex = cgmasterGroup.group(QStringLiteral( "LevelMeter#%1" ).arg( mParaminstanceIndex ));
  KConfigCompilerSignallingItem  *itemBypass;
  KConfigBaseEE::ItemBool  *innerItemBypass;
  innerItemBypass = new KConfigBaseEE::ItemBool( currentGroup(), QStringLiteral( "bypass" ), mBypass, false );
  itemBypass = new KConfigCompilerSignallingItem(innerItemBypass, this, notifyFunction, signalBypassChanged);
  itemBypass->setWriteFlags(KConfigBase::Notify);
  itemBypass->setGroup(cgLevelMeterinstanceIndex);
  addItem( itemBypass, QStringLiteral( "bypass" ) );
}

bool DbLevelMeter::defaultBypassValue_helper() const
{

  return false;
}

DbLevelMeter::~DbLevelMeter()
{
}


void DbLevelMeter::itemChanged(quint64 signalFlag) {

  switch (signalFlag) {
  case signalBypassChanged:
    Q_EMIT bypassChanged();
    break;
  }
}
