Rename TQCStringList

pull/1/head
Timothy Pearson 13 years ago
parent 1c76ebb4b7
commit 60933ac14a

@ -886,7 +886,7 @@ gboolean dcop_client_receive( DcopClient *client,
{ {
GList *list = 0; GList *list = 0;
*reply_type = strdup( "TQCStringList" ); *reply_type = strdup( "QCStringList" );
*reply_data = dcop_data_ref( dcop_data_new() ); *reply_data = dcop_data_ref( dcop_data_new() );
if ( object_dict ) if ( object_dict )

@ -192,7 +192,7 @@ gboolean dcop_object_real_process( DcopObject *obj, const gchar *fun, dcop_data
if ( strcmp( fun, "interfaces()" ) == 0 ) if ( strcmp( fun, "interfaces()" ) == 0 )
{ {
*reply_type = g_strdup( "TQCStringList" ); *reply_type = g_strdup( "QCStringList" );
*reply_data = dcop_data_ref( dcop_data_new() ); *reply_data = dcop_data_ref( dcop_data_new() );
strlist = klass->interfaces( obj ); strlist = klass->interfaces( obj );
@ -203,7 +203,7 @@ gboolean dcop_object_real_process( DcopObject *obj, const gchar *fun, dcop_data
} }
else if ( strcmp( fun, "functions()" ) == 0 ) else if ( strcmp( fun, "functions()" ) == 0 )
{ {
*reply_type = strdup( "TQCStringList" ); *reply_type = strdup( "QCStringList" );
*reply_data = dcop_data_ref( dcop_data_new() ); *reply_data = dcop_data_ref( dcop_data_new() );
strlist = klass->functions( obj ); strlist = klass->functions( obj );
@ -235,8 +235,8 @@ GList *dcop_object_interfaces( DcopObject *obj )
GList *dcop_object_real_functions( DcopObject *client ) GList *dcop_object_real_functions( DcopObject *client )
{ {
GList *res = 0; GList *res = 0;
res = g_list_append( res, g_strdup( "TQCStringList interfaces()" ) ); res = g_list_append( res, g_strdup( "QCStringList interfaces()" ) );
res = g_list_append( res, g_strdup( "TQCStringList functions()" ) ); res = g_list_append( res, g_strdup( "QCStringList functions()" ) );
return res; return res;
} }

@ -286,26 +286,26 @@ void generateSkel( const TQString& idl, const TQString& filename, TQDomElement d
str << " return TRUE;" << endl; str << " return TRUE;" << endl;
str << "}" << endl << endl; str << "}" << endl << endl;
str << "TQCStringList " << className; str << "QCStringList " << className;
str << "::interfaces()" << endl; str << "::interfaces()" << endl;
str << "{" << endl; str << "{" << endl;
if (!DCOPParent.isEmpty()) { if (!DCOPParent.isEmpty()) {
str << " TQCStringList ifaces = " << DCOPParent << "::interfaces();" << endl; str << " QCStringList ifaces = " << DCOPParent << "::interfaces();" << endl;
} else { } else {
str << " TQCStringList ifaces;" << endl; str << " QCStringList ifaces;" << endl;
} }
str << " ifaces += \"" << className << "\";" << endl; str << " ifaces += \"" << className << "\";" << endl;
str << " return ifaces;" << endl; str << " return ifaces;" << endl;
str << "}" << endl << endl; str << "}" << endl << endl;
str << "TQCStringList " << className; str << "QCStringList " << className;
str << "::functions()" << endl; str << "::functions()" << endl;
str << "{" << endl; str << "{" << endl;
if (!DCOPParent.isEmpty()) { if (!DCOPParent.isEmpty()) {
str << " TQCStringList funcs = " << DCOPParent << "::functions();" << endl; str << " QCStringList funcs = " << DCOPParent << "::functions();" << endl;
} else { } else {
str << " TQCStringList funcs;" << endl; str << " QCStringList funcs;" << endl;
} }
str << " for ( int i = 0; " << className << "_ftable[i][2]; i++ ) {" << endl; str << " for ( int i = 0; " << className << "_ftable[i][2]; i++ ) {" << endl;
str << "\tTQCString func = " << className << "_ftable[i][0];" << endl; str << "\tTQCString func = " << className << "_ftable[i][0];" << endl;

@ -233,7 +233,7 @@ sub remoteFunctions($app, $object)
returns a reference to an array with the names of the functions the specified interface supports. returns a reference to an array with the names of the functions the specified interface supports.
The functions are returned as their signatures with parameter names and return type like The functions are returned as their signatures with parameter names and return type like
TQCStringList functions() QCStringList functions()
sub normalizeSignature($signature) sub normalizeSignature($signature)
@ -260,7 +260,7 @@ mapped to scalar
=item * TQString (no Unicode support yet, just latin 1) =item * TQString (no Unicode support yet, just latin 1)
mapped to scalar mapped to scalar
=item * TQCStringList =item * QCStringList
mapped to a reference to an array of scalars. mapped to a reference to an array of scalars.
=item * TQStringList =item * TQStringList

@ -110,22 +110,22 @@ SV *TQStringToSV(const TQString &data, SV * self = 0)
return data.isNull() ? &PL_sv_undef : newSVpv((char *)data.latin1(), 0); return data.isNull() ? &PL_sv_undef : newSVpv((char *)data.latin1(), 0);
} }
TQCStringList TQCStringListFromSV(SV *data) QCStringList QCStringListFromSV(SV *data)
{ {
if (!SvROK(data)) if (!SvROK(data))
croak("DCOP: Not reference"); croak("DCOP: Not reference");
if (SvTYPE(SvRV(data)) != SVt_PVAV) if (SvTYPE(SvRV(data)) != SVt_PVAV)
croak("DCOP: Not an array reference"); croak("DCOP: Not an array reference");
TQCStringList result; QCStringList result;
for (int i = 0; i <= av_len((AV*)SvRV(data)); i++) for (int i = 0; i <= av_len((AV*)SvRV(data)); i++)
result.append(TQCStringFromSV(av_fetch((AV*)SvRV(data), i, 0)[0])); result.append(TQCStringFromSV(av_fetch((AV*)SvRV(data), i, 0)[0]));
return result; return result;
} }
SV *TQCStringListToSV(const TQCStringList &data, SV * self = 0) SV *QCStringListToSV(const QCStringList &data, SV * self = 0)
{ {
AV *result = newAV(); AV *result = newAV();
for (TQCStringList::ConstIterator i = data.begin(); i != data.end(); i++) for (QCStringList::ConstIterator i = data.begin(); i != data.end(); i++)
av_push(result, TQCStringToSV(*i)); av_push(result, TQCStringToSV(*i));
return newRV((SV*)result); return newRV((SV*)result);
} }
@ -277,7 +277,7 @@ TQByteArray mapArgs(const TQCString &func, SV **data, int n)
else CHECK_ARG(bool) else CHECK_ARG(bool)
else CHECK_ARG(TQCString) else CHECK_ARG(TQCString)
else CHECK_ARG(TQString) else CHECK_ARG(TQString)
else CHECK_ARG(TQCStringList) else CHECK_ARG(QCStringList)
else CHECK_ARG(TQStringList) else CHECK_ARG(TQStringList)
else CHECK_ARG(TQPoint) else CHECK_ARG(TQPoint)
else CHECK_ARG(TQSize) else CHECK_ARG(TQSize)
@ -302,7 +302,7 @@ SV* mapReply(const TQCString &replyType, const TQByteArray &replyData, SV *self)
else CHECK_REPLY(bool) else CHECK_REPLY(bool)
else CHECK_REPLY(TQCString) else CHECK_REPLY(TQCString)
else CHECK_REPLY(TQString) else CHECK_REPLY(TQString)
else CHECK_REPLY(TQCStringList) else CHECK_REPLY(QCStringList)
else CHECK_REPLY(TQStringList) else CHECK_REPLY(TQStringList)
else CHECK_REPLY(TQPoint) else CHECK_REPLY(TQPoint)
else CHECK_REPLY(TQSize) else CHECK_REPLY(TQSize)
@ -452,25 +452,25 @@ DCOPClient::isApplicationRegistered(app)
OUTPUT: OUTPUT:
RETVAL RETVAL
TQCStringList QCStringList
DCOPClient::registeredApplications() DCOPClient::registeredApplications()
OUTPUT: OUTPUT:
RETVAL RETVAL
TQCStringList QCStringList
DCOPClient::remoteObjects(app) DCOPClient::remoteObjects(app)
TQCString app TQCString app
OUTPUT: OUTPUT:
RETVAL RETVAL
TQCStringList QCStringList
DCOPClient::remoteInterfaces(app, obj) DCOPClient::remoteInterfaces(app, obj)
TQCString app TQCString app
TQCString obj TQCString obj
OUTPUT: OUTPUT:
RETVAL RETVAL
TQCStringList QCStringList
DCOPClient::remoteFunctions(app, obj) DCOPClient::remoteFunctions(app, obj)
TQCString app TQCString app
TQCString obj TQCString obj

@ -62,7 +62,7 @@ sub query {
print "[$#$list]"; print "[$#$list]";
check ($list = $client->remoteFunctions("kdesktop", "qt")); check ($list = $client->remoteFunctions("kdesktop", "qt"));
print "[$#$list]"; print "[$#$list]";
check grep /^TQCStringList functions\(\)$/, @$list; check grep /^QCStringList functions\(\)$/, @$list;
} }
sub calls { sub calls {

@ -1,7 +1,7 @@
TYPEMAP TYPEMAP
DCOPClient * O_OBJECT DCOPClient * O_OBJECT
TQCString T_QCSTRING TQCString T_QCSTRING
TQCStringList T_QCSTRINGLIST QCStringList T_QCSTRINGLIST
INPUT INPUT
O_OBJECT O_OBJECT
@ -20,4 +20,4 @@ O_OBJECT
T_QCSTRING T_QCSTRING
sv_setsv($arg, TQCStringToSV($var)); sv_setsv($arg, TQCStringToSV($var));
T_QCSTRINGLIST T_QCSTRINGLIST
sv_setsv($arg, TQCStringListToSV($var)); sv_setsv($arg, QCStringListToSV($var));

@ -25,7 +25,7 @@ DCOP retquires a TQString. In addition to the fundemental types, more complex QT
coded, such as TQRect (which converts to a Python tuple ( (x1,y1), (x2,y2) ) ). coded, such as TQRect (which converts to a Python tuple ( (x1,y1), (x2,y2) ) ).
Documentation is auto-generated out of marshal_funcs.data, creating file marshal_funcs_doc.html, Documentation is auto-generated out of marshal_funcs.data, creating file marshal_funcs_doc.html,
which details how each DCOP type (e.g. TQString, TQRect, int, TQCStringList) is represented in Python. which details how each DCOP type (e.g. TQString, TQRect, int, QCStringList) is represented in Python.
In this implementation, each DCOP type is represented by a basic Python type - numeric, tuple, etc. In this implementation, each DCOP type is represented by a basic Python type - numeric, tuple, etc.
There are no "QT bindings" necessary. There are no "QT bindings" necessary.

@ -50,7 +50,7 @@ namespace PythonDCOP {
if (ty=="TQStringList") if (ty=="TQStringList")
return marshalList(PCOPType("TQString"), obj, str); return marshalList(PCOPType("TQString"), obj, str);
if (ty=="TQCStringList") if (ty=="QCStringList")
return marshalList(PCOPType("TQCString"), obj, str); return marshalList(PCOPType("TQCString"), obj, str);
if (ty=="TQValueList" && type.leftType()) if (ty=="TQValueList" && type.leftType())
return marshalList(*type.leftType(), obj, str); return marshalList(*type.leftType(), obj, str);
@ -68,7 +68,7 @@ namespace PythonDCOP {
if (ty=="TQStringList") if (ty=="TQStringList")
return demarshalList(PCOPType("TQString"), str); return demarshalList(PCOPType("TQString"), str);
if (ty=="TQCStringList") if (ty=="QCStringList")
return demarshalList(PCOPType("TQCString"), str); return demarshalList(PCOPType("TQCString"), str);
if (ty=="TQValueList" && type.leftType()) if (ty=="TQValueList" && type.leftType())
return demarshalList(*type.leftType(), str); return demarshalList(*type.leftType(), str);

@ -165,8 +165,8 @@ namespace PythonDCOP {
return ok; return ok;
} }
TQCStringList PCOPObject::functions() { QCStringList PCOPObject::functions() {
TQCStringList funcs = DCOPObject::functions(); QCStringList funcs = DCOPObject::functions();
for(TQAsciiDictIterator<PCOPMethod> it(m_methods); for(TQAsciiDictIterator<PCOPMethod> it(m_methods);
it.current(); ++it) { it.current(); ++it) {
PCOPMethod *meth = it.current(); PCOPMethod *meth = it.current();
@ -385,11 +385,11 @@ namespace PythonDCOP {
return ((PCOPMethod*)this)->m_params.at( i ); return ((PCOPMethod*)this)->m_params.at( i );
} }
PCOPClass::PCOPClass( const TQCStringList& methods ) PCOPClass::PCOPClass( const QCStringList& methods )
{ {
m_methods.setAutoDelete( true ); m_methods.setAutoDelete( true );
TQCStringList::ConstIterator it = methods.begin(); QCStringList::ConstIterator it = methods.begin();
for( ; it != methods.end(); ++it ) for( ; it != methods.end(); ++it )
{ {
PCOPMethod* m = new PCOPMethod( *it ); PCOPMethod* m = new PCOPMethod( *it );
@ -511,14 +511,14 @@ namespace PythonDCOP {
// Determine which functions are available. // Determine which functions are available.
// //
bool ok = false; bool ok = false;
TQCStringList funcs = dcop->remoteFunctions( appname, objname, &ok ); QCStringList funcs = dcop->remoteFunctions( appname, objname, &ok );
if ( !ok ) if ( !ok )
{ {
PyErr_SetString( PyExc_RuntimeError, "Object is not accessible." ); PyErr_SetString( PyExc_RuntimeError, "Object is not accessible." );
return NULL; return NULL;
} }
// for ( TQCStringList::Iterator it = funcs.begin(); it != funcs.end(); ++it ) { // for ( QCStringList::Iterator it = funcs.begin(); it != funcs.end(); ++it ) {
// qDebug( "%s", (*it).data() ); // qDebug( "%s", (*it).data() );
// } // }
@ -585,12 +585,12 @@ namespace PythonDCOP {
PyObject* application_list( PyObject */*self*/, PyObject */*args*/ ) PyObject* application_list( PyObject */*self*/, PyObject */*args*/ )
{ {
TQCStringList apps = Client::instance()->dcop()->registeredApplications(); QCStringList apps = Client::instance()->dcop()->registeredApplications();
PyObject *l = PyList_New( apps.count() ); PyObject *l = PyList_New( apps.count() );
TQCStringList::ConstIterator it = apps.begin(); QCStringList::ConstIterator it = apps.begin();
TQCStringList::ConstIterator end = apps.end(); QCStringList::ConstIterator end = apps.end();
unsigned int i = 0; unsigned int i = 0;
for (; it != end; ++it, i++ ) for (; it != end; ++it, i++ )
PyList_SetItem( l, i, PyString_FromString( (*it).data() ) ); PyList_SetItem( l, i, PyString_FromString( (*it).data() ) );
@ -601,7 +601,7 @@ namespace PythonDCOP {
PyObject *object_list( PyObject */*self*/, PyObject *args) { PyObject *object_list( PyObject */*self*/, PyObject *args) {
const char *app; const char *app;
if (PyArg_ParseTuple(args, (char*)"s", &app)) { if (PyArg_ParseTuple(args, (char*)"s", &app)) {
TQCStringList objects = Client::instance()->dcop()->remoteObjects(TQCString(app)); QCStringList objects = Client::instance()->dcop()->remoteObjects(TQCString(app));
return make_py_list(objects); return make_py_list(objects);
} }
return NULL; return NULL;
@ -610,7 +610,7 @@ namespace PythonDCOP {
PyObject *method_list( PyObject */*self*/, PyObject *args) { PyObject *method_list( PyObject */*self*/, PyObject *args) {
const char *app, *obj; const char *app, *obj;
if (PyArg_ParseTuple(args, (char*)"ss", &app, &obj)) { if (PyArg_ParseTuple(args, (char*)"ss", &app, &obj)) {
TQCStringList methods = Client::instance()->dcop()->remoteFunctions(TQCString(app), TQCString(obj) ); QCStringList methods = Client::instance()->dcop()->remoteFunctions(TQCString(app), TQCString(obj) );
return make_py_list(methods); return make_py_list(methods);
} }
return NULL; return NULL;
@ -730,10 +730,10 @@ namespace PythonDCOP {
// helpers // helpers
PyObject *make_py_list( const TQCStringList &qt_list) { PyObject *make_py_list( const QCStringList &qt_list) {
PyObject *l = PyList_New(qt_list.count()); PyObject *l = PyList_New(qt_list.count());
uint c=0; uint c=0;
for(TQCStringList::ConstIterator it = qt_list.begin(); for(QCStringList::ConstIterator it = qt_list.begin();
it!=qt_list.end(); it!=qt_list.end();
++it,c++) ++it,c++)
PyList_SetItem(l, c, PyString_FromString( (*it).data() ) ); PyList_SetItem(l, c, PyString_FromString( (*it).data() ) );

@ -41,7 +41,7 @@ namespace PythonDCOP {
// helpers... // helpers...
void delete_dcop_object(void *vp); void delete_dcop_object(void *vp);
PyObject *make_py_list(const TQCStringList &qt_list); PyObject *make_py_list(const QCStringList &qt_list);
/** /**
* Used by the Python interface to talk to DCOP * Used by the Python interface to talk to DCOP
@ -90,7 +90,7 @@ namespace PythonDCOP {
/** /**
* Return list of supported functions (methods). * Return list of supported functions (methods).
*/ */
virtual TQCStringList functions(); virtual QCStringList functions();
/** /**
* Set the list of methods that this object handles. * Set the list of methods that this object handles.
@ -188,12 +188,12 @@ namespace PythonDCOP {
class PCOPClass class PCOPClass
{ {
public: public:
PCOPClass( const TQCStringList& dcop_style_methods); PCOPClass( const QCStringList& dcop_style_methods);
~PCOPClass(); ~PCOPClass();
const PCOPMethod* method( const TQCString &name, PyObject *argTuple = 0 ); const PCOPMethod* method( const TQCString &name, PyObject *argTuple = 0 );
TQCStringList m_ifaces; QCStringList m_ifaces;
TQAsciiDict<PCOPMethod> m_methods; TQAsciiDict<PCOPMethod> m_methods;
}; };

@ -6,8 +6,8 @@ Run python server.py, then in another console:
qt qt
parrot parrot
[julian] julian$ dcop `dcop | grep petshop` parrot [julian] julian$ dcop `dcop | grep petshop` parrot
TQCStringList interfaces() QCStringList interfaces()
TQCStringList functions() QCStringList functions()
TQString squawk(TQString) TQString squawk(TQString)
void setAge(int) void setAge(int)
int age() int age()

@ -2050,12 +2050,12 @@ sub jniArgTocplusplus
} else { } else {
$jniArg = "($cplusplusType)*(TQStrList*) KDESupport::toKFileItemList(env, $argName, &_qlist_$argName)"; $jniArg = "($cplusplusType)*(TQStrList*) KDESupport::toKFileItemList(env, $argName, &_qlist_$argName)";
} }
} elsif ( $cplusplusType =~ /TQCStringList/ ) { } elsif ( $cplusplusType =~ /QCStringList/ ) {
$jniLocal ="static TQCStringList* _qlist_$argName = 0;\n"; $jniLocal ="static QCStringList* _qlist_$argName = 0;\n";
if ( $cplusplusType =~ /[\*]/ ) { if ( $cplusplusType =~ /[\*]/ ) {
$jniArg = "($cplusplusType) KDESupport::toTQCStringList(env, $argName, &_qlist_$argName)"; $jniArg = "($cplusplusType) KDESupport::toQCStringList(env, $argName, &_qlist_$argName)";
} else { } else {
$jniArg = "($cplusplusType)*(TQCStringList*) KDESupport::toTQCStringList(env, $argName, &_qlist_$argName)"; $jniArg = "($cplusplusType)*(QCStringList*) KDESupport::toQCStringList(env, $argName, &_qlist_$argName)";
} }
} elsif ( $cplusplusType =~ /KURL::List/ ) { } elsif ( $cplusplusType =~ /KURL::List/ ) {
$jniLocal ="static KURL::List* _qlist_$argName = 0;\n"; $jniLocal ="static KURL::List* _qlist_$argName = 0;\n";
@ -2237,7 +2237,7 @@ sub jniToReturnValue($$$)
$returnCall .= "\treturn (jobject) QtSupport::arrayWith$1(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n"; $returnCall .= "\treturn (jobject) QtSupport::arrayWith$1(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n";
} elsif ( $cplusplusType =~ /DOM::(NodeList|StyleSheetList|MediaList)\s*([\*\&])?\s*$/ ) { } elsif ( $cplusplusType =~ /DOM::(NodeList|StyleSheetList|MediaList)\s*([\*\&])?\s*$/ ) {
$returnCall .= "\treturn (jobject) KDESupport::arrayWith$1(env, (DOM::$1 *) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n"; $returnCall .= "\treturn (jobject) KDESupport::arrayWith$1(env, (DOM::$1 *) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n";
} elsif ( $cplusplusType =~ /(TQCStringList|KFileItemList|KFileViewItemList)\s*([\*\&])?\s*$/ ) { } elsif ( $cplusplusType =~ /(QCStringList|KFileItemList|KFileViewItemList)\s*([\*\&])?\s*$/ ) {
$returnCall .= "\treturn (jobject) KDESupport::arrayWith$1(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n"; $returnCall .= "\treturn (jobject) KDESupport::arrayWith$1(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n";
} elsif ( $cplusplusType =~ /(KTrader::OfferList)\s*([\*\&])?\s*$/ ) { } elsif ( $cplusplusType =~ /(KTrader::OfferList)\s*([\*\&])?\s*$/ ) {
$returnCall .= "\treturn (jobject) KDESupport::arrayWithOfferList(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n"; $returnCall .= "\treturn (jobject) KDESupport::arrayWithOfferList(env, ($1*) " . ($2 eq "\*" ? "" : "&") . "_qlist);\n";

@ -1507,7 +1507,7 @@ BEGIN
'TQCString' => 'qt_QCString*' , 'TQCString' => 'qt_QCString*' ,
'TQCString*' => 'qt_QCString*' , 'TQCString*' => 'qt_QCString*' ,
'TQCStringLess*' => 'qt_QCStringLess*' , 'TQCStringLess*' => 'qt_QCStringLess*' ,
'TQCStringList' => 'kde_QCStringList*' , 'QCStringList' => 'kde_QCStringList*' ,
'TQCache*' => 'qt_QCache*', 'TQCache*' => 'qt_QCache*',
'TQCacheIterator*' => 'qt_QCacheIterator*', 'TQCacheIterator*' => 'qt_QCacheIterator*',
'TQCanvas*' => 'qt_QCanvas*' , 'TQCanvas*' => 'qt_QCanvas*' ,

@ -295,7 +295,7 @@
ready for the KDE 2.2 beta baseline. ready for the KDE 2.2 beta baseline.
2001-05-07 Richard Dale <duke@tipitina.demon.co.uk 2001-05-07 Richard Dale <duke@tipitina.demon.co.uk
* Sources regenerated for KDE 2.2. * Sources regenerated for KDE 2.2.
* TQByteArray/TQCStringList now converted correctly. * TQByteArray/QCStringList now converted correctly.
* String conversions improved, no longer inline, but all methods in * String conversions improved, no longer inline, but all methods in
QtSupport.h/cpp. QtSupport.h/cpp.
* Argc/Argv parameters all have dummy java argv[0] added. * Argc/Argv parameters all have dummy java argv[0] added.

@ -452,73 +452,73 @@ static TQCString* _qcstring_appId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_registeredApplications(JNIEnv* env, jobject obj) Java_org_kde_koala_DCOPClient_registeredApplications(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->registeredApplications(); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->registeredApplications();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteFunctions__Ljava_lang_String_2Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp, jstring remObj) Java_org_kde_koala_DCOPClient_remoteFunctions__Ljava_lang_String_2Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp, jstring remObj)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
static TQCString* _qcstring_remObj = 0; static TQCString* _qcstring_remObj = 0;
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteFunctions((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj)); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteFunctions((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj));
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteFunctions__Ljava_lang_String_2Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jstring remObj, jbooleanArray ok) Java_org_kde_koala_DCOPClient_remoteFunctions__Ljava_lang_String_2Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jstring remObj, jbooleanArray ok)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
static TQCString* _qcstring_remObj = 0; static TQCString* _qcstring_remObj = 0;
bool* _bool_ok = QtSupport::toBooleanPtr(env, ok); bool* _bool_ok = QtSupport::toBooleanPtr(env, ok);
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteFunctions((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj), (bool*) _bool_ok); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteFunctions((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj), (bool*) _bool_ok);
env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok); env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok);
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteInterfaces__Ljava_lang_String_2Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp, jstring remObj) Java_org_kde_koala_DCOPClient_remoteInterfaces__Ljava_lang_String_2Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp, jstring remObj)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
static TQCString* _qcstring_remObj = 0; static TQCString* _qcstring_remObj = 0;
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteInterfaces((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj)); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteInterfaces((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj));
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteInterfaces__Ljava_lang_String_2Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jstring remObj, jbooleanArray ok) Java_org_kde_koala_DCOPClient_remoteInterfaces__Ljava_lang_String_2Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jstring remObj, jbooleanArray ok)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
static TQCString* _qcstring_remObj = 0; static TQCString* _qcstring_remObj = 0;
bool* _bool_ok = QtSupport::toBooleanPtr(env, ok); bool* _bool_ok = QtSupport::toBooleanPtr(env, ok);
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteInterfaces((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj), (bool*) _bool_ok); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteInterfaces((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remObj, &_qcstring_remObj), (bool*) _bool_ok);
env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok); env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok);
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteObjects__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp) Java_org_kde_koala_DCOPClient_remoteObjects__Ljava_lang_String_2(JNIEnv* env, jobject obj, jstring remApp)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteObjects((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp)); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteObjects((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp));
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPClient_remoteObjects__Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jbooleanArray ok) Java_org_kde_koala_DCOPClient_remoteObjects__Ljava_lang_String_2_3Z(JNIEnv* env, jobject obj, jstring remApp, jbooleanArray ok)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qcstring_remApp = 0; static TQCString* _qcstring_remApp = 0;
bool* _bool_ok = QtSupport::toBooleanPtr(env, ok); bool* _bool_ok = QtSupport::toBooleanPtr(env, ok);
_qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteObjects((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (bool*) _bool_ok); _qlist = ((DCOPClient*) QtSupport::getQt(env, obj))->remoteObjects((const TQCString&)*(TQCString*) QtSupport::toTQCString(env, remApp, &_qcstring_remApp), (bool*) _bool_ok);
env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok); env->SetBooleanArrayRegion(ok, 0, 1, (jboolean*) _bool_ok);
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT void JNICALL JNIEXPORT void JNICALL

@ -83,17 +83,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPObject_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_DCOPObject_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPObject_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_DCOPObject_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->functions(); _qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL
@ -108,17 +108,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPObject_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_DCOPObject_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_DCOPObject_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_DCOPObject_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL

@ -115,10 +115,10 @@ Java_org_kde_koala_KCmdLineArgs_enable_1i18n(JNIEnv* env, jclass cls)
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KCmdLineArgs_getOptionList(JNIEnv* env, jobject obj, jstring option) Java_org_kde_koala_KCmdLineArgs_getOptionList(JNIEnv* env, jobject obj, jstring option)
{ {
TQCStringList _qlist; QCStringList _qlist;
static TQCString* _qstring_option = 0; static TQCString* _qstring_option = 0;
_qlist = ((KCmdLineArgs*) QtSupport::getQt(env, obj))->getOptionList((const char*) QtSupport::toCharString(env, option, &_qstring_option)); _qlist = ((KCmdLineArgs*) QtSupport::getQt(env, obj))->getOptionList((const char*) QtSupport::toCharString(env, option, &_qstring_option));
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jstring JNICALL JNIEXPORT jstring JNICALL

@ -198,7 +198,7 @@ KDESupport::toTQByteArrayFromStream(JNIEnv * env, TQByteArray * qbyteArray, jobj
} }
jobject jobject
KDESupport::arrayWithTQCStringList(JNIEnv * env, TQCStringList * qcstringList) KDESupport::arrayWithQCStringList(JNIEnv * env, QCStringList * qcstringList)
{ {
jobject objectArray; jobject objectArray;
jclass cls; jclass cls;
@ -220,7 +220,7 @@ KDESupport::arrayWithTQCStringList(JNIEnv * env, TQCStringList * qcstringList)
return NULL; return NULL;
} }
TQCStringList::Iterator it; QCStringList::Iterator it;
for (it = qcstringList->begin(); it != qcstringList->end(); ++it) { for (it = qcstringList->begin(); it != qcstringList->end(); ++it) {
TQCString currentTQCString = (TQCString) *it; TQCString currentTQCString = (TQCString) *it;
@ -502,8 +502,8 @@ KDESupport::arrayWithMediaList(JNIEnv * env, DOM::MediaList * mediaList)
return (jobject) objectArray; return (jobject) objectArray;
} }
TQCStringList * QCStringList *
KDESupport::toTQCStringList(JNIEnv * env, jobjectArray stringList, TQCStringList ** qstringList) KDESupport::toQCStringList(JNIEnv * env, jobjectArray stringList, QCStringList ** qstringList)
{ {
int length; int length;
int index; int index;
@ -511,7 +511,7 @@ KDESupport::toTQCStringList(JNIEnv * env, jobjectArray stringList, TQCStringList
static TQCString * _qstring_temp = 0; static TQCString * _qstring_temp = 0;
if (*qstringList == 0) { if (*qstringList == 0) {
*qstringList = new TQCStringList(); *qstringList = new QCStringList();
} }
(*qstringList)->clear(); (*qstringList)->clear();

@ -57,7 +57,7 @@ public:
static TQByteArray * toTQByteArrayFromStream(JNIEnv * env, TQByteArray * byteArray, jobject byteStream); static TQByteArray * toTQByteArrayFromStream(JNIEnv * env, TQByteArray * byteArray, jobject byteStream);
/** Returns a Java ArrayList for the various types of KDE List */ /** Returns a Java ArrayList for the various types of KDE List */
static jobject arrayWithTQCStringList(JNIEnv * env, TQCStringList * qcstringList); static jobject arrayWithQCStringList(JNIEnv * env, QCStringList * qcstringList);
static jobject arrayWithOfferList(JNIEnv * env, KTrader::OfferList * offerList); static jobject arrayWithOfferList(JNIEnv * env, KTrader::OfferList * offerList);
static jobject arrayWithKMainWindowList(JNIEnv * env, TQPtrList<KMainWindow>* memberList); static jobject arrayWithKMainWindowList(JNIEnv * env, TQPtrList<KMainWindow>* memberList);
static jobject arrayWithKFileItemList(JNIEnv * env, KFileItemList * itemList); static jobject arrayWithKFileItemList(JNIEnv * env, KFileItemList * itemList);
@ -66,8 +66,8 @@ public:
static jobject arrayWithStyleSheetList(JNIEnv * env, DOM::StyleSheetList * styleSheetList); static jobject arrayWithStyleSheetList(JNIEnv * env, DOM::StyleSheetList * styleSheetList);
static jobject arrayWithMediaList(JNIEnv * env, DOM::MediaList * mediaList); static jobject arrayWithMediaList(JNIEnv * env, DOM::MediaList * mediaList);
/** Convert from ArrayList to TQCStringList */ /** Convert from ArrayList to QCStringList */
static TQCStringList * toTQCStringList(JNIEnv * env, jobjectArray stringList, TQCStringList ** qstringList); static QCStringList * toQCStringList(JNIEnv * env, jobjectArray stringList, QCStringList ** qstringList);
}; };

@ -144,17 +144,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KPanelAppMenu_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KPanelAppMenu_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KPanelAppMenu_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_KPanelAppMenu_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->functions(); _qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL
@ -225,17 +225,17 @@ static TQString* _qstring_text = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KPanelAppMenu_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KPanelAppMenu_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KPanelAppMenu_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_KPanelAppMenu_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*)(KPanelAppMenu*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL

@ -221,17 +221,17 @@ Java_org_kde_koala_KSycoca_flagError(JNIEnv* env, jclass cls)
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KSycoca_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KSycoca_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KSycoca_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_KSycoca_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->functions(); _qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL
@ -246,17 +246,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KSycoca_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KSycoca_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KSycoca_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_KSycoca_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*)(KSycoca*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL

@ -157,17 +157,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KUniqueApplication_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KUniqueApplication_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KUniqueApplication_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_KUniqueApplication_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->functions(); _qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL
@ -182,17 +182,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KUniqueApplication_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_KUniqueApplication_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_KUniqueApplication_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_KUniqueApplication_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*)(KUniqueApplication*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL

@ -115,17 +115,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Observer_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_Observer_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Observer_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_Observer_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->functions(); _qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jboolean JNICALL JNIEXPORT jboolean JNICALL
@ -140,17 +140,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Observer_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_Observer_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Observer_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_Observer_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*)(Observer*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT void JNICALL JNIEXPORT void JNICALL

@ -201,17 +201,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Scheduler_functionsDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_Scheduler_functionsDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->functionsDynamic(); _qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->functionsDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Scheduler_functions(JNIEnv* env, jobject obj) Java_org_kde_koala_Scheduler_functions(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((KIO::Scheduler*) QtSupport::getQt(env, obj))->functions(); _qlist = ((KIO::Scheduler*) QtSupport::getQt(env, obj))->functions();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
@ -234,17 +234,17 @@ static TQCString* _qcstring_objId = 0;
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Scheduler_interfacesDynamic(JNIEnv* env, jobject obj) Java_org_kde_koala_Scheduler_interfacesDynamic(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->interfacesDynamic(); _qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->interfacesDynamic();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT jobject JNICALL JNIEXPORT jobject JNICALL
Java_org_kde_koala_Scheduler_interfaces(JNIEnv* env, jobject obj) Java_org_kde_koala_Scheduler_interfaces(JNIEnv* env, jobject obj)
{ {
TQCStringList _qlist; QCStringList _qlist;
_qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->interfaces(); _qlist = ((DCOPObject*)(KIO::Scheduler*) QtSupport::getQt(env, obj))->interfaces();
return (jobject) KDESupport::arrayWithTQCStringList(env, (TQCStringList*) &_qlist); return (jobject) KDESupport::arrayWithQCStringList(env, (QCStringList*) &_qlist);
} }
JNIEXPORT void JNICALL JNIEXPORT void JNICALL

@ -643,7 +643,7 @@ TQString JSDCOPClient::dcopStart( const TQString &appName, const TQStringList& a
TQStringList JSDCOPClient::remoteFunctions( const TQString & remApp, const TQString & remObj ) TQStringList JSDCOPClient::remoteFunctions( const TQString & remApp, const TQString & remObj )
{ {
TQStringList returnList; TQStringList returnList;
TQCStringList lst = kapp->dcopClient()->remoteFunctions(remApp.local8Bit(), remObj.local8Bit()); QCStringList lst = kapp->dcopClient()->remoteFunctions(remApp.local8Bit(), remObj.local8Bit());
for(uint idx = 0; idx < lst.count(); ++idx) for(uint idx = 0; idx < lst.count(); ++idx)
returnList += lst[idx]; returnList += lst[idx];
return returnList; return returnList;
@ -652,7 +652,7 @@ TQStringList JSDCOPClient::remoteFunctions( const TQString & remApp, const TQStr
TQStringList JSDCOPClient::remoteInterfaces( const TQString & remApp, const TQString & remObj ) TQStringList JSDCOPClient::remoteInterfaces( const TQString & remApp, const TQString & remObj )
{ {
TQStringList returnList; TQStringList returnList;
TQCStringList lst = kapp->dcopClient()->remoteInterfaces(remApp.local8Bit(), remObj.local8Bit()); QCStringList lst = kapp->dcopClient()->remoteInterfaces(remApp.local8Bit(), remObj.local8Bit());
for(uint idx = 0; idx < lst.count(); ++idx) for(uint idx = 0; idx < lst.count(); ++idx)
returnList += lst[idx]; returnList += lst[idx];
return returnList; return returnList;
@ -661,7 +661,7 @@ TQStringList JSDCOPClient::remoteInterfaces( const TQString & remApp, const TQSt
TQStringList JSDCOPClient::remoteObjects( const TQString & remApp ) TQStringList JSDCOPClient::remoteObjects( const TQString & remApp )
{ {
TQStringList returnList; TQStringList returnList;
TQCStringList lst = kapp->dcopClient()->remoteObjects(remApp.local8Bit()); QCStringList lst = kapp->dcopClient()->remoteObjects(remApp.local8Bit());
for(uint idx = 0; idx < lst.count(); ++idx) for(uint idx = 0; idx < lst.count(); ++idx)
returnList += lst[idx]; returnList += lst[idx];
return returnList; return returnList;
@ -670,7 +670,7 @@ TQStringList JSDCOPClient::remoteObjects( const TQString & remApp )
TQStringList JSDCOPClient::registeredApplications( ) TQStringList JSDCOPClient::registeredApplications( )
{ {
TQStringList returnList; TQStringList returnList;
TQCStringList lst = kapp->dcopClient()->registeredApplications( ); QCStringList lst = kapp->dcopClient()->registeredApplications( );
for(uint idx = 0; idx < lst.count(); ++idx) for(uint idx = 0; idx < lst.count(); ++idx)
returnList += lst[idx]; returnList += lst[idx];
return returnList; return returnList;
@ -720,7 +720,7 @@ JSDCOPInterface::JSDCOPInterface( KJS::Interpreter *js, TQObject * parent, const
m_Members.clear(); m_Members.clear();
} }
TQCStringList JSDCOPInterface::functionsDynamic( ) QCStringList JSDCOPInterface::functionsDynamic( )
{ {
return m_Members; return m_Members;
} }
@ -1002,7 +1002,7 @@ TQVariant JSDCOPClient::demarshall( const TQCString & type, TQDataStream & reply
reply >> result; reply >> result;
return TQVariant(result); return TQVariant(result);
} }
else if ( type == "TQCStringList") else if ( type == "QCStringList")
{ {
TQStringList result; TQStringList result;
reply >> result; reply >> result;

@ -57,13 +57,13 @@ class JSDCOPInterface : public BindingObject, public DCOPObject
public: public:
JSDCOPInterface( KJS::Interpreter *js, TQObject *parent, const char *name=0 ); JSDCOPInterface( KJS::Interpreter *js, TQObject *parent, const char *name=0 );
virtual ~JSDCOPInterface(); virtual ~JSDCOPInterface();
TQCStringList functionsDynamic(); QCStringList functionsDynamic();
bool processDynamic (const TQCString &fun, const TQByteArray &data, TQCString &replyType, TQByteArray &replyData); bool processDynamic (const TQCString &fun, const TQByteArray &data, TQCString &replyType, TQByteArray &replyData);
public slots: public slots:
void publish(const TQString& signature); void publish(const TQString& signature);
private: private:
TQCStringList m_Members; QCStringList m_Members;
KJS::Interpreter *m_js; KJS::Interpreter *m_js;
}; };

@ -434,7 +434,7 @@ CCMAIL: kde-bindings@kde.org
2004-07-17 Richard Dale <Richard_Dale@tipitina.demon.co.uk> 2004-07-17 Richard Dale <Richard_Dale@tipitina.demon.co.uk>
* More missing DCOP marshallers - TQStringList and TQCStringList * More missing DCOP marshallers - TQStringList and QCStringList
* A class with a 'k_dcop' slots declaration can now be an instance * A class with a 'k_dcop' slots declaration can now be an instance
of DCOPObject of DCOPObject
* Converted the 'petshop' DCOP server example from pytde python * Converted the 'petshop' DCOP server example from pytde python

@ -136,8 +136,8 @@ smokeStackToStream(Marshall *m, Smoke::Stack stack, TQDataStream* stream, int it
TQCString temp((const TQCString&) *((TQCString *) stack[i].s_voidp)); TQCString temp((const TQCString&) *((TQCString *) stack[i].s_voidp));
*stream << temp; *stream << temp;
break; break;
} else if (strcmp(t.name(), "TQCStringList") == 0) { } else if (strcmp(t.name(), "QCStringList") == 0) {
TQCStringList temp((const TQCStringList&) *((TQCStringList *) stack[i].s_voidp)); QCStringList temp((const QCStringList&) *((QCStringList *) stack[i].s_voidp));
*stream << temp; *stream << temp;
break; break;
} else if (strcmp(t.name(), "TQStringList") == 0) { } else if (strcmp(t.name(), "TQStringList") == 0) {
@ -294,10 +294,10 @@ smokeStackFromStream(Marshall *m, Smoke::Stack stack, TQDataStream* stream, int
*stream >> temp; *stream >> temp;
stack[i].s_voidp = new TQCString(temp); stack[i].s_voidp = new TQCString(temp);
break; break;
} else if (strcmp(t.name(), "TQCStringList") == 0) { } else if (strcmp(t.name(), "QCStringList") == 0) {
TQCStringList temp; QCStringList temp;
*stream >> temp; *stream >> temp;
stack[i].s_voidp = new TQCStringList(temp); stack[i].s_voidp = new QCStringList(temp);
break; break;
} else if (strcmp(t.name(), "TQStringList") == 0) { } else if (strcmp(t.name(), "TQStringList") == 0) {
TQStringList temp; TQStringList temp;

@ -123,7 +123,7 @@ void marshall_QCStringList(Marshall *m) {
} }
int count = RARRAY(list)->len; int count = RARRAY(list)->len;
TQCStringList *stringlist = new TQCStringList; QCStringList *stringlist = new QCStringList;
for(long i = 0; i < count; i++) { for(long i = 0; i < count; i++) {
VALUE item = rb_ary_entry(list, i); VALUE item = rb_ary_entry(list, i);
@ -139,7 +139,7 @@ void marshall_QCStringList(Marshall *m) {
if(m->cleanup()) { if(m->cleanup()) {
rb_ary_clear(list); rb_ary_clear(list);
for(TQCStringList::Iterator it = stringlist->begin(); it != stringlist->end(); ++it) for(QCStringList::Iterator it = stringlist->begin(); it != stringlist->end(); ++it)
rb_ary_push(list, rb_str_new2(static_cast<const char *>(*it))); rb_ary_push(list, rb_str_new2(static_cast<const char *>(*it)));
delete stringlist; delete stringlist;
} }
@ -147,14 +147,14 @@ void marshall_QCStringList(Marshall *m) {
} }
case Marshall::ToVALUE: case Marshall::ToVALUE:
{ {
TQCStringList *stringlist = static_cast<TQCStringList *>(m->item().s_voidp); QCStringList *stringlist = static_cast<QCStringList *>(m->item().s_voidp);
if(!stringlist) { if(!stringlist) {
*(m->var()) = Qnil; *(m->var()) = Qnil;
break; break;
} }
VALUE av = rb_ary_new(); VALUE av = rb_ary_new();
for(TQCStringList::Iterator it = stringlist->begin(); it != stringlist->end(); ++it) { for(QCStringList::Iterator it = stringlist->begin(); it != stringlist->end(); ++it) {
VALUE rv = rb_str_new2(static_cast<const char *>((*it))); VALUE rv = rb_str_new2(static_cast<const char *>((*it)));
rb_ary_push(av, rv); rb_ary_push(av, rv);
} }
@ -1377,7 +1377,7 @@ void marshall_QMapTQCStringDCOPRef(Marshall *m) {
} }
TypeHandler KDE_handlers[] = { TypeHandler KDE_handlers[] = {
{ "TQCStringList", marshall_QCStringList }, { "QCStringList", marshall_QCStringList },
{ "KCmdLineOptions*", marshall_KCmdLineOptions }, { "KCmdLineOptions*", marshall_KCmdLineOptions },
{ "KActionPtrList", marshall_KActionList }, { "KActionPtrList", marshall_KActionList },
{ "TQPtrList<KAction>", marshall_KActionList }, { "TQPtrList<KAction>", marshall_KActionList },

@ -385,7 +385,7 @@
include/qtjava. include/qtjava.
2001-05-07 Richard Dale <duke@tipitina.demon.co.uk 2001-05-07 Richard Dale <duke@tipitina.demon.co.uk
* Sources regenerated for KDE 2.2. * Sources regenerated for KDE 2.2.
* TQByteArray/TQCStringList now converted correctly. * TQByteArray/QCStringList now converted correctly.
* String conversions improved, no longer inline, but all methods in * String conversions improved, no longer inline, but all methods in
QtSupport.h/cpp. QtSupport.h/cpp.
* Argc/Argv parameters all have dummy java argv[0] added. * Argc/Argv parameters all have dummy java argv[0] added.

Loading…
Cancel
Save