Changeset View
Changeset View
Standalone View
Standalone View
autotests/kconfig_compiler/test5.cpp.ref
Show First 20 Lines • Show All 63 Lines • ▼ Show 20 Line(s) | 39 | QColor defaultColor[4] = { Qt::red, Qt::blue, Qt::green, Qt::black }; | |||
---|---|---|---|---|---|
64 | } | 64 | } | ||
65 | { | 65 | { | ||
66 | KConfigSkeleton::ItemEnum::Choice choice; | 66 | KConfigSkeleton::ItemEnum::Choice choice; | ||
67 | choice.name = QStringLiteral("PumpNDump"); | 67 | choice.name = QStringLiteral("PumpNDump"); | ||
68 | valuesMouseAction.append( choice ); | 68 | valuesMouseAction.append( choice ); | ||
69 | } | 69 | } | ||
70 | KConfigSkeleton::ItemEnum *itemMouseAction[3]; | 70 | KConfigSkeleton::ItemEnum *itemMouseAction[3]; | ||
71 | itemMouseAction[0] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "right_mouse_action" ), mMouseAction[0], valuesMouseAction, Decrypt ); | 71 | itemMouseAction[0] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "right_mouse_action" ), mMouseAction[0], valuesMouseAction, Decrypt ); | ||
72 | itemMouseAction[0]->setValueForChoice(QStringLiteral( "CrashNBurn" ), QStringLiteral( "Crash'n Burn" )); | ||||
72 | addItem( itemMouseAction[0], QStringLiteral( "MouseActionright" ) ); | 73 | addItem( itemMouseAction[0], QStringLiteral( "MouseActionright" ) ); | ||
73 | itemMouseAction[1] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "mid_mouse_action" ), mMouseAction[1], valuesMouseAction, Encrypt ); | 74 | itemMouseAction[1] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "mid_mouse_action" ), mMouseAction[1], valuesMouseAction, Encrypt ); | ||
75 | itemMouseAction[1]->setValueForChoice(QStringLiteral( "CrashNBurn" ), QStringLiteral( "Crash'n Burn" )); | ||||
74 | addItem( itemMouseAction[1], QStringLiteral( "MouseActionmid" ) ); | 76 | addItem( itemMouseAction[1], QStringLiteral( "MouseActionmid" ) ); | ||
75 | itemMouseAction[2] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "left_mouse_action" ), mMouseAction[2], valuesMouseAction, PumpNDump ); | 77 | itemMouseAction[2] = new KConfigSkeleton::ItemEnum( currentGroup(), QStringLiteral( "left_mouse_action" ), mMouseAction[2], valuesMouseAction, PumpNDump ); | ||
78 | itemMouseAction[2]->setValueForChoice(QStringLiteral( "CrashNBurn" ), QStringLiteral( "Crash'n Burn" )); | ||||
76 | addItem( itemMouseAction[2], QStringLiteral( "MouseActionleft" ) ); | 79 | addItem( itemMouseAction[2], QStringLiteral( "MouseActionleft" ) ); | ||
77 | KConfigSkeleton::ItemString *itemFooBar; | 80 | KConfigSkeleton::ItemString *itemFooBar; | ||
78 | itemFooBar = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "foo bar" ), mFooBar ); | 81 | itemFooBar = new KConfigSkeleton::ItemString( currentGroup(), QStringLiteral( "foo bar" ), mFooBar ); | ||
79 | addItem( itemFooBar, QStringLiteral( "FooBar" ) ); | 82 | addItem( itemFooBar, QStringLiteral( "FooBar" ) ); | ||
80 | KConfigSkeleton::ItemInt *itemAge; | 83 | KConfigSkeleton::ItemInt *itemAge; | ||
81 | itemAge = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "Age" ), mAge, 35 ); | 84 | itemAge = new KConfigSkeleton::ItemInt( currentGroup(), QStringLiteral( "Age" ), mAge, 35 ); | ||
82 | itemAge->setMinValue(8); | 85 | itemAge->setMinValue(8); | ||
83 | itemAge->setMaxValue(88); | 86 | itemAge->setMaxValue(88); | ||
84 | addItem( itemAge, QStringLiteral( "Age" ) ); | 87 | addItem( itemAge, QStringLiteral( "Age" ) ); | ||
85 | } | 88 | } | ||
86 | 89 | | |||
87 | Test5::~Test5() | 90 | Test5::~Test5() | ||
88 | { | 91 | { | ||
89 | s_globalTest5()->q = nullptr; | 92 | s_globalTest5()->q = nullptr; | ||
90 | } | 93 | } | ||
91 | 94 | |