/****************************************************************************
**
** DCOP Skeleton generated by dcopidl2cpp from khtml_iface.kidl
**
** WARNING! All changes made in this file will be lost!
**
*****************************************************************************/

#include "/usr/src/ports/kdelibs3/kdelibs3-3.5.10-11.i686/src/kdelibs-3.5.10/khtml/khtml_iface.h"

#include <kdatastream.h>
#include <qasciidict.h>


static const int KHTMLPartIface_fhash = 37;
static const char* const KHTMLPartIface_ftable[37][3] = {
    { "KURL", "url()", "url()" },
    { "bool", "closeURL()", "closeURL()" },
    { "void", "setJScriptEnabled(bool)", "setJScriptEnabled(bool enable)" },
    { "bool", "jScriptEnabled()", "jScriptEnabled()" },
    { "void", "setMetaRefreshEnabled(bool)", "setMetaRefreshEnabled(bool enable)" },
    { "bool", "metaRefreshEnabled()", "metaRefreshEnabled()" },
    { "void", "setDNDEnabled(bool)", "setDNDEnabled(bool b)" },
    { "bool", "dndEnabled()", "dndEnabled()" },
    { "void", "setJavaEnabled(bool)", "setJavaEnabled(bool enable)" },
    { "bool", "javaEnabled()", "javaEnabled()" },
    { "void", "setPluginsEnabled(bool)", "setPluginsEnabled(bool enable)" },
    { "bool", "pluginsEnabled()", "pluginsEnabled()" },
    { "void", "setAutoloadImages(bool)", "setAutoloadImages(bool enable)" },
    { "bool", "autoloadImages()", "autoloadImages()" },
    { "void", "setOnlyLocalReferences(bool)", "setOnlyLocalReferences(bool enable)" },
    { "bool", "onlyLocalReferences()", "onlyLocalReferences()" },
    { "bool", "setEncoding(QString)", "setEncoding(QString name)" },
    { "QString", "encoding()", "encoding()" },
    { "void", "setUserStyleSheet(QString)", "setUserStyleSheet(QString styleSheet)" },
    { "void", "setFixedFont(QString)", "setFixedFont(QString name)" },
    { "bool", "gotoAnchor(QString)", "gotoAnchor(QString name)" },
    { "bool", "nextAnchor()", "nextAnchor()" },
    { "bool", "prevAnchor()", "prevAnchor()" },
    { "void", "activateNode()", "activateNode()" },
    { "QString", "selectedText()", "selectedText()" },
    { "void", "selectAll()", "selectAll()" },
    { "QString", "lastModified()", "lastModified()" },
    { "ASYNC", "print(bool)", "print(bool quick)" },
    { "void", "debugRenderTree()", "debugRenderTree()" },
    { "void", "debugDOMTree()", "debugDOMTree()" },
    { "void", "viewDocumentSource()", "viewDocumentSource()" },
    { "void", "viewFrameSource()", "viewFrameSource()" },
    { "void", "saveBackground(QString)", "saveBackground(QString url)" },
    { "void", "saveDocument(QString)", "saveDocument(QString url)" },
    { "QString", "evalJS(QString)", "evalJS(QString script)" },
    { "void", "stopAnimations()", "stopAnimations()" },
    { 0, 0, 0 }
};
static const int KHTMLPartIface_ftable_hiddens[36] = {
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
    0,
};

bool KHTMLPartIface::process(const QCString &fun, const QByteArray &data, QCString& replyType, QByteArray &replyData)
{
    static QAsciiDict<int>* fdict = 0;
    if ( !fdict ) {
	fdict = new QAsciiDict<int>( KHTMLPartIface_fhash, true, false );
	for ( int i = 0; KHTMLPartIface_ftable[i][1]; i++ )
	    fdict->insert( KHTMLPartIface_ftable[i][1],  new int( i ) );
    }
    int* fp = fdict->find( fun );
    switch ( fp?*fp:-1) {
    case 0: { // KURL url()
	replyType = KHTMLPartIface_ftable[0][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << url( );
    } break;
    case 1: { // bool closeURL()
	replyType = KHTMLPartIface_ftable[1][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << closeURL( );
    } break;
    case 2: { // void setJScriptEnabled(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[2][0]; 
	setJScriptEnabled(arg0 );
    } break;
    case 3: { // bool jScriptEnabled()
	replyType = KHTMLPartIface_ftable[3][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << jScriptEnabled( );
    } break;
    case 4: { // void setMetaRefreshEnabled(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[4][0]; 
	setMetaRefreshEnabled(arg0 );
    } break;
    case 5: { // bool metaRefreshEnabled()
	replyType = KHTMLPartIface_ftable[5][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << metaRefreshEnabled( );
    } break;
    case 6: { // void setDNDEnabled(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[6][0]; 
	setDNDEnabled(arg0 );
    } break;
    case 7: { // bool dndEnabled()
	replyType = KHTMLPartIface_ftable[7][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << dndEnabled( );
    } break;
    case 8: { // void setJavaEnabled(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[8][0]; 
	setJavaEnabled(arg0 );
    } break;
    case 9: { // bool javaEnabled()
	replyType = KHTMLPartIface_ftable[9][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << javaEnabled( );
    } break;
    case 10: { // void setPluginsEnabled(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[10][0]; 
	setPluginsEnabled(arg0 );
    } break;
    case 11: { // bool pluginsEnabled()
	replyType = KHTMLPartIface_ftable[11][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << pluginsEnabled( );
    } break;
    case 12: { // void setAutoloadImages(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[12][0]; 
	setAutoloadImages(arg0 );
    } break;
    case 13: { // bool autoloadImages()
	replyType = KHTMLPartIface_ftable[13][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << autoloadImages( );
    } break;
    case 14: { // void setOnlyLocalReferences(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[14][0]; 
	setOnlyLocalReferences(arg0 );
    } break;
    case 15: { // bool onlyLocalReferences()
	replyType = KHTMLPartIface_ftable[15][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << onlyLocalReferences( );
    } break;
    case 16: { // bool setEncoding(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[16][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << setEncoding(arg0 );
    } break;
    case 17: { // QString encoding()
	replyType = KHTMLPartIface_ftable[17][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << encoding( );
    } break;
    case 18: { // void setUserStyleSheet(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[18][0]; 
	setUserStyleSheet(arg0 );
    } break;
    case 19: { // void setFixedFont(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[19][0]; 
	setFixedFont(arg0 );
    } break;
    case 20: { // bool gotoAnchor(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[20][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << gotoAnchor(arg0 );
    } break;
    case 21: { // bool nextAnchor()
	replyType = KHTMLPartIface_ftable[21][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << nextAnchor( );
    } break;
    case 22: { // bool prevAnchor()
	replyType = KHTMLPartIface_ftable[22][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << prevAnchor( );
    } break;
    case 23: { // void activateNode()
	replyType = KHTMLPartIface_ftable[23][0]; 
	activateNode( );
    } break;
    case 24: { // QString selectedText()
	replyType = KHTMLPartIface_ftable[24][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << selectedText( );
    } break;
    case 25: { // void selectAll()
	replyType = KHTMLPartIface_ftable[25][0]; 
	selectAll( );
    } break;
    case 26: { // QString lastModified()
	replyType = KHTMLPartIface_ftable[26][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << lastModified( );
    } break;
    case 27: { // void print(bool)
	bool arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[27][0]; 
	print(arg0 );
    } break;
    case 28: { // void debugRenderTree()
	replyType = KHTMLPartIface_ftable[28][0]; 
	debugRenderTree( );
    } break;
    case 29: { // void debugDOMTree()
	replyType = KHTMLPartIface_ftable[29][0]; 
	debugDOMTree( );
    } break;
    case 30: { // void viewDocumentSource()
	replyType = KHTMLPartIface_ftable[30][0]; 
	viewDocumentSource( );
    } break;
    case 31: { // void viewFrameSource()
	replyType = KHTMLPartIface_ftable[31][0]; 
	viewFrameSource( );
    } break;
    case 32: { // void saveBackground(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[32][0]; 
	saveBackground(arg0 );
    } break;
    case 33: { // void saveDocument(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[33][0]; 
	saveDocument(arg0 );
    } break;
    case 34: { // QString evalJS(QString)
	QString arg0;
	QDataStream arg( data, IO_ReadOnly );
	if (arg.atEnd()) return false;
	arg >> arg0;
	replyType = KHTMLPartIface_ftable[34][0]; 
	QDataStream _replyStream( replyData, IO_WriteOnly );
	_replyStream << evalJS(arg0 );
    } break;
    case 35: { // void stopAnimations()
	replyType = KHTMLPartIface_ftable[35][0]; 
	stopAnimations( );
    } break;
    default: 
	return DCOPObject::process( fun, data, replyType, replyData );
    }
    return true;
}

QCStringList KHTMLPartIface::interfaces()
{
    QCStringList ifaces = DCOPObject::interfaces();
    ifaces += "KHTMLPartIface";
    return ifaces;
}

QCStringList KHTMLPartIface::functions()
{
    QCStringList funcs = DCOPObject::functions();
    for ( int i = 0; KHTMLPartIface_ftable[i][2]; i++ ) {
	if (KHTMLPartIface_ftable_hiddens[i])
	    continue;
	QCString func = KHTMLPartIface_ftable[i][0];
	func += ' ';
	func += KHTMLPartIface_ftable[i][2];
	funcs << func;
    }
    return funcs;
}


