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.
83 lines
3.5 KiB
83 lines
3.5 KiB
15 years ago
|
// This file is generated by kconfig_compiler from test4.kcfg.
|
||
|
// All changes you do to this file will be lost.
|
||
|
|
||
|
#include "test4.h"
|
||
|
|
||
|
#include <kstaticdeleter.h>
|
||
|
|
||
|
Test4 *Test4::mSelf = 0;
|
||
|
static KStaticDeleter<Test4> staticTest4Deleter;
|
||
|
|
||
|
Test4 *Test4::self()
|
||
|
{
|
||
|
if ( !mSelf ) {
|
||
|
staticTest4Deleter.setObject( mSelf, new Test4() );
|
||
|
mSelf->readConfig();
|
||
|
}
|
||
|
|
||
|
return mSelf;
|
||
|
}
|
||
|
|
||
|
const char* const Test4::EnumButton::enumToString[] = { "right", "mid", "left" };
|
||
|
|
||
|
Test4::Test4( )
|
||
14 years ago
|
: KConfigSkeleton( TQString::tqfromLatin1( "test4rc" ) )
|
||
15 years ago
|
{
|
||
|
mSelf = this;
|
||
14 years ago
|
setCurrentGroup( TQString::tqfromLatin1( "Foo" ) );
|
||
15 years ago
|
|
||
15 years ago
|
TQColor defaultColor[4] = { Qt::red, Qt::blue, Qt::green, Qt::black };
|
||
15 years ago
|
KConfigSkeleton::ItemColor *itemColor[4];
|
||
14 years ago
|
itemColor[0] = new KConfigSkeleton::ItemColor( currentGroup(), TQString::tqfromLatin1( "color #0" ), mColor[0], defaultColor[0] );
|
||
|
addItem( itemColor[0], TQString::tqfromLatin1( "Color0" ) );
|
||
|
itemColor[1] = new KConfigSkeleton::ItemColor( currentGroup(), TQString::tqfromLatin1( "color #1" ), mColor[1], defaultColor[1] );
|
||
|
addItem( itemColor[1], TQString::tqfromLatin1( "Color1" ) );
|
||
|
itemColor[2] = new KConfigSkeleton::ItemColor( currentGroup(), TQString::tqfromLatin1( "color #2" ), mColor[2], defaultColor[2] );
|
||
|
addItem( itemColor[2], TQString::tqfromLatin1( "Color2" ) );
|
||
|
itemColor[3] = new KConfigSkeleton::ItemColor( currentGroup(), TQString::tqfromLatin1( "color #3" ), mColor[3], defaultColor[3] );
|
||
|
addItem( itemColor[3], TQString::tqfromLatin1( "Color3" ) );
|
||
15 years ago
|
TQValueList<KConfigSkeleton::ItemEnum::Choice> valuesMouseAction;
|
||
15 years ago
|
{
|
||
|
KConfigSkeleton::ItemEnum::Choice choice;
|
||
14 years ago
|
choice.name = TQString::tqfromLatin1( "Encrypt" );
|
||
15 years ago
|
valuesMouseAction.append( choice );
|
||
|
}
|
||
|
{
|
||
|
KConfigSkeleton::ItemEnum::Choice choice;
|
||
14 years ago
|
choice.name = TQString::tqfromLatin1( "Decrypt" );
|
||
15 years ago
|
valuesMouseAction.append( choice );
|
||
|
}
|
||
|
{
|
||
|
KConfigSkeleton::ItemEnum::Choice choice;
|
||
14 years ago
|
choice.name = TQString::tqfromLatin1( "CrashNBurn" );
|
||
15 years ago
|
valuesMouseAction.append( choice );
|
||
|
}
|
||
|
{
|
||
|
KConfigSkeleton::ItemEnum::Choice choice;
|
||
14 years ago
|
choice.name = TQString::tqfromLatin1( "PumpNDump" );
|
||
15 years ago
|
valuesMouseAction.append( choice );
|
||
|
}
|
||
|
KConfigSkeleton::ItemEnum *itemMouseAction[3];
|
||
14 years ago
|
itemMouseAction[0] = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "right_mouse_action" ), mMouseAction[0], valuesMouseAction, EnumMouseAction::Decrypt );
|
||
|
addItem( itemMouseAction[0], TQString::tqfromLatin1( "MouseActionright" ) );
|
||
|
itemMouseAction[1] = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "mid_mouse_action" ), mMouseAction[1], valuesMouseAction, EnumMouseAction::Encrypt );
|
||
|
addItem( itemMouseAction[1], TQString::tqfromLatin1( "MouseActionmid" ) );
|
||
|
itemMouseAction[2] = new KConfigSkeleton::ItemEnum( currentGroup(), TQString::tqfromLatin1( "left_mouse_action" ), mMouseAction[2], valuesMouseAction, EnumMouseAction::PumpNDump );
|
||
|
addItem( itemMouseAction[2], TQString::tqfromLatin1( "MouseActionleft" ) );
|
||
15 years ago
|
KConfigSkeleton::ItemString *itemFooBar;
|
||
14 years ago
|
itemFooBar = new KConfigSkeleton::ItemString( currentGroup(), TQString::tqfromLatin1( "foo bar" ), mFooBar );
|
||
|
addItem( itemFooBar, TQString::tqfromLatin1( "FooBar" ) );
|
||
15 years ago
|
KConfigSkeleton::ItemInt *itemAge;
|
||
14 years ago
|
itemAge = new KConfigSkeleton::ItemInt( currentGroup(), TQString::tqfromLatin1( "Age" ), mAge, 35 );
|
||
15 years ago
|
itemAge->setMinValue(8);
|
||
|
itemAge->setMaxValue(88);
|
||
14 years ago
|
addItem( itemAge, TQString::tqfromLatin1( "Age" ) );
|
||
15 years ago
|
}
|
||
|
|
||
|
Test4::~Test4()
|
||
|
{
|
||
|
if ( mSelf == this )
|
||
|
staticTest4Deleter.setObject( mSelf, 0, false );
|
||
|
}
|
||
|
|