mirror of
https://bitbucket.org/smil3y/kdelibs.git
synced 2025-02-24 19:02:48 +00:00
48 lines
1.1 KiB
Text
48 lines
1.1 KiB
Text
// This file is generated by kconfig_compiler from test10.kcfg.
|
|
// All changes you do to this file will be lost.
|
|
|
|
#include "test10.h"
|
|
|
|
#include <kglobal.h>
|
|
#include <QtCore/QFile>
|
|
|
|
class Test10Helper
|
|
{
|
|
public:
|
|
Test10Helper() : q(0) {}
|
|
~Test10Helper() { delete q; }
|
|
Test10 *q;
|
|
};
|
|
K_GLOBAL_STATIC(Test10Helper, s_globalTest10)
|
|
Test10 *Test10::self()
|
|
{
|
|
if (!s_globalTest10->q) {
|
|
new Test10;
|
|
s_globalTest10->q->readConfig();
|
|
}
|
|
|
|
return s_globalTest10->q;
|
|
}
|
|
|
|
Test10::Test10( )
|
|
: KConfigSkeleton( QLatin1String( "test10rc" ) )
|
|
{
|
|
Q_ASSERT(!s_globalTest10->q);
|
|
s_globalTest10->q = this;
|
|
setCurrentGroup( QLatin1String( "Foo" ) );
|
|
|
|
KConfigSkeleton::ItemUrl *itemFooBar;
|
|
itemFooBar = new KConfigSkeleton::ItemUrl( currentGroup(), QLatin1String( "foo bar" ), mFooBar );
|
|
addItem( itemFooBar, QLatin1String( "FooBar" ) );
|
|
KConfigSkeleton::ItemUrlList *itemBarFoo;
|
|
itemBarFoo = new KConfigSkeleton::ItemUrlList( currentGroup(), QLatin1String( "bar foo" ), mBarFoo );
|
|
addItem( itemBarFoo, QLatin1String( "BarFoo" ) );
|
|
}
|
|
|
|
Test10::~Test10()
|
|
{
|
|
if (!s_globalTest10.isDestroyed()) {
|
|
s_globalTest10->q = 0;
|
|
}
|
|
}
|
|
|