/***************************************************************************
                            kde_KConfig.cpp -  description
                             -------------------
    begin                : Wed Feb  6 15:12:26 2002
    copyright            : (C) 2000-2001 Lost Highway Ltd. All rights reserved.
    email                : Lost_Highway@tipitina.demon.co.uk
    generated by         : duke@tipitina on Wed Feb  6 15:12:26 2002, using kalyptus 0.9.
 ***************************************************************************/

/***************************************************************************
 *                                                                         *
 *   This library is free software; you can redistribute it and/or modify  *
 *   it under the terms of the GNU Library General Public License as       *
 *   published by the Free Software Foundation; either version 2 of the    *
 *   License, or (at your option) any later version.                       *
 *                                                                         *
 ***************************************************************************/

extern "C" {
#include "kde_KConfig.h"
}

#include <kconfig.h>

class KConfigBridge : public KConfig
{
public:
	KConfigBridge(const QString& fileName, bool bReadOnly, bool bUseKDEGlobals, const char* resType) : KConfig(fileName, bReadOnly, bUseKDEGlobals, resType) {}
	~KConfigBridge() {}
	 bool  protected_internalHasGroup(const QCString& group) {
		return ( bool ) KConfig::internalHasGroup(group);
	}
	 KEntryMap  protected_internalEntryMap(const QString& pGroup) {
		return ( KEntryMap ) KConfig::internalEntryMap(pGroup);
	}
	 KEntryMap  protected_internalEntryMap() {
		return ( KEntryMap ) KConfig::internalEntryMap();
	}
	void protected_putData(const KEntryKey& _key, const KEntry& _data, bool _checkGroup) {
		KConfig::putData(_key, _data, _checkGroup);
		return;
	}
	 KEntry  protected_lookupData(const KEntryKey& _key) {
		return ( KEntry ) KConfig::lookupData(_key);
	}
	void childEvent(QChildEvent* arg1) {
		if (Qt_EventDelegate == 0L || !(*Qt_EventDelegate)(this, "childEvent", arg1, "QChildEvent")) {
			QObject::childEvent(arg1);
		}
		return;
	}
	void customEvent(QCustomEvent* arg1) {
		if (Qt_EventDelegate == 0L || !(*Qt_EventDelegate)(this, "customEvent", arg1, "QCustomEvent")) {
			QObject::customEvent(arg1);
		}
		return;
	}
	void timerEvent(QTimerEvent* arg1) {
		if (Qt_EventDelegate == 0L || !(*Qt_EventDelegate)(this, "timerEvent", arg1, "QTimerEvent")) {
			QObject::timerEvent(arg1);
		}
		return;
	}
};

kde_KConfig * kde_new_KConfig(qt_QString * fileName, int bReadOnly, int bUseKDEGlobals, char* resType){
	return (kde_KConfig *) new KConfigBridge((QString&)* (QString*)fileName, (bool)bReadOnly, (bool)bUseKDEGlobals, (char*)resType);
}
void kde_del_KConfig( kde_KConfig* p ){
	delete (KConfigBridge*) p;
}
void kde_KConfig_rollback( kde_KConfig* instPointer,int bDeep){
	((KConfigBridge*)instPointer)->rollback((bool)bDeep);
	return;
}
qt_QStringList* kde_KConfig_groupList( kde_KConfig* instPointer){
	return (qt_QStringList*)new QStringList(((KConfigBridge*)instPointer)->groupList());
}
void kde_KConfig_reparseConfiguration( kde_KConfig* instPointer){
	((KConfigBridge*)instPointer)->reparseConfiguration();
	return;
}
int kde_KConfig_internalHasGroup( kde_KConfig* instPointer,qt_QCString* group){
	return (int) ((KConfigBridge*)instPointer)->protected_internalHasGroup((QCString&)* (QCString*)group);
}
//kde_KEntryMap* kde_KConfig_internalEntryMap( kde_KConfig* instPointer,qt_QString * pGroup){
//	return (kde_KEntryMap*)new KEntryMap(((KConfigBridge*)instPointer)->protected_internalEntryMap((QString&)* (QString*)pGroup));
//}
//kde_KEntryMap* kde_KConfig_internalEntryMap1( kde_KConfig* instPointer){
//	return (kde_KEntryMap*)new KEntryMap(((KConfigBridge*)instPointer)->protected_internalEntryMap());
//}
void kde_KConfig_putData( kde_KConfig* instPointer,kde_KEntryKey* _key, kde_KEntry* _data, int _checkGroup){
	((KConfigBridge*)instPointer)->protected_putData((KEntryKey&)* (KEntryKey*)_key, (KEntry&)* (KEntry*)_data, (bool)_checkGroup);
	return;
}
kde_KEntry* kde_KConfig_lookupData( kde_KConfig* instPointer,kde_KEntryKey* _key){
	return (kde_KEntry*)new KEntry(((KConfigBridge*)instPointer)->protected_lookupData((KEntryKey&)* (KEntryKey*)_key));
}
