You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
tdelibs/kdecore/kconfig_compiler/tests/test5.cpp.ref

83 lines
3.4 KiB

// This file is generated by kconfig_compiler from test5.kcfg.
// All changes you do to this file will be lost.
#include "test5.h"
#include <kstaticdeleter.h>
Test5 *Test5::mSelf = 0;
static KStaticDeleter<Test5> staticTest5Deleter;
Test5 *Test5::self()
{
if ( !mSelf ) {
staticTest5Deleter.setObject( mSelf, new Test5() );
mSelf->readConfig();
}
return mSelf;
}
const char* const Test5::EnumButtonToString[] = { "right", "mid", "left" };
Test5::Test5( )
: KConfigSkeleton( QString::fromLatin1( "test4rc" ) )
{
mSelf = this;
setCurrentGroup( QString::fromLatin1( "Foo" ) );
QColor defaultColor[4] = { Qt::red, Qt::blue, Qt::green, Qt::black };
KConfigSkeleton::ItemColor *itemColor[4];
itemColor[0] = new KConfigSkeleton::ItemColor( currentGroup(), QString::fromLatin1( "color #0" ), mColor[0], defaultColor[0] );
addItem( itemColor[0], QString::fromLatin1( "Color0" ) );
itemColor[1] = new KConfigSkeleton::ItemColor( currentGroup(), QString::fromLatin1( "color #1" ), mColor[1], defaultColor[1] );
addItem( itemColor[1], QString::fromLatin1( "Color1" ) );
itemColor[2] = new KConfigSkeleton::ItemColor( currentGroup(), QString::fromLatin1( "color #2" ), mColor[2], defaultColor[2] );
addItem( itemColor[2], QString::fromLatin1( "Color2" ) );
itemColor[3] = new KConfigSkeleton::ItemColor( currentGroup(), QString::fromLatin1( "color #3" ), mColor[3], defaultColor[3] );
addItem( itemColor[3], QString::fromLatin1( "Color3" ) );
QValueList<KConfigSkeleton::ItemEnum::Choice> valuesMouseAction;
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QString::fromLatin1( "Encrypt" );
valuesMouseAction.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QString::fromLatin1( "Decrypt" );
valuesMouseAction.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QString::fromLatin1( "CrashNBurn" );
valuesMouseAction.append( choice );
}
{
KConfigSkeleton::ItemEnum::Choice choice;
choice.name = QString::fromLatin1( "PumpNDump" );
valuesMouseAction.append( choice );
}
KConfigSkeleton::ItemEnum *itemMouseAction[3];
itemMouseAction[0] = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "right_mouse_action" ), mMouseAction[0], valuesMouseAction, Decrypt );
addItem( itemMouseAction[0], QString::fromLatin1( "MouseActionright" ) );
itemMouseAction[1] = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "mid_mouse_action" ), mMouseAction[1], valuesMouseAction, Encrypt );
addItem( itemMouseAction[1], QString::fromLatin1( "MouseActionmid" ) );
itemMouseAction[2] = new KConfigSkeleton::ItemEnum( currentGroup(), QString::fromLatin1( "left_mouse_action" ), mMouseAction[2], valuesMouseAction, PumpNDump );
addItem( itemMouseAction[2], QString::fromLatin1( "MouseActionleft" ) );
KConfigSkeleton::ItemString *itemFooBar;
itemFooBar = new KConfigSkeleton::ItemString( currentGroup(), QString::fromLatin1( "foo bar" ), mFooBar );
addItem( itemFooBar, QString::fromLatin1( "FooBar" ) );
KConfigSkeleton::ItemInt *itemAge;
itemAge = new KConfigSkeleton::ItemInt( currentGroup(), QString::fromLatin1( "Age" ), mAge, 35 );
itemAge->setMinValue(8);
itemAge->setMaxValue(88);
addItem( itemAge, QString::fromLatin1( "Age" ) );
}
Test5::~Test5()
{
if ( mSelf == this )
staticTest5Deleter.setObject( mSelf, 0, false );
}