summaryrefslogtreecommitdiffstats
path: root/lib/kross/api
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commitb6edfe41c9395f2e20784cbf0e630af6426950a3 (patch)
tree56ed9b871d4296e6c15949c24e16420be1b28697 /lib/kross/api
parentef39e8e4178a8f98cf5f154916ba0f03e4855206 (diff)
downloadkoffice-b6edfe41c9395f2e20784cbf0e630af6426950a3.tar.gz
koffice-b6edfe41c9395f2e20784cbf0e630af6426950a3.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/koffice@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'lib/kross/api')
-rw-r--r--lib/kross/api/callable.cpp4
-rw-r--r--lib/kross/api/event.h16
-rw-r--r--lib/kross/api/eventsignal.cpp2
-rw-r--r--lib/kross/api/eventslot.cpp6
-rw-r--r--lib/kross/api/interpreter.cpp2
-rw-r--r--lib/kross/api/qtobject.cpp16
6 files changed, 23 insertions, 23 deletions
diff --git a/lib/kross/api/callable.cpp b/lib/kross/api/callable.cpp
index a7a394ba..f095f596 100644
--- a/lib/kross/api/callable.cpp
+++ b/lib/kross/api/callable.cpp
@@ -47,7 +47,7 @@ const TQString Callable::getClassName() const
bool Callable::hasChild(const TQString& name) const
{
- return m_tqchildren.tqcontains(name);
+ return m_tqchildren.contains(name);
}
Object::Ptr Callable::getChild(const TQString& name) const
@@ -66,7 +66,7 @@ bool Callable::addChild(const TQString& name, Object* object)
krossdebug( TQString("Kross::Api::Callable::addChild() object.name='%1' object.classname='%2'")
.tqarg(name).tqarg(object->getClassName()) );
#endif
- m_tqchildren.tqreplace(name, Object::Ptr(object));
+ m_tqchildren.replace(name, Object::Ptr(object));
return true;
}
diff --git a/lib/kross/api/event.h b/lib/kross/api/event.h
index e378052b..26a92117 100644
--- a/lib/kross/api/event.h
+++ b/lib/kross/api/event.h
@@ -97,7 +97,7 @@ namespace Kross { namespace Api {
*/
inline void addFunction(const TQString& name, FunctionPtr function)
{
- m_functions.tqreplace(name, new Function0<T>(static_cast<T*>(this), function));
+ m_functions.replace(name, new Function0<T>(static_cast<T*>(this), function));
}
/**
@@ -114,7 +114,7 @@ namespace Kross { namespace Api {
*/
inline void addFunction(const TQString& name, Function* function)
{
- m_functions.tqreplace(name, function);
+ m_functions.replace(name, function);
}
/**
@@ -124,7 +124,7 @@ namespace Kross { namespace Api {
template<class RETURNOBJ, class ARG1OBJ, class ARG2OBJ, class ARG3OBJ, class ARG4OBJ, class INSTANCE, typename METHOD>
inline void addFunction4(const TQString& name, INSTANCE* instance, METHOD method, ARG1OBJ* arg1 = 0, ARG2OBJ* arg2 = 0, ARG3OBJ* arg3 = 0, ARG4OBJ* arg4 = 0)
{
- m_functions.tqreplace(name,
+ m_functions.replace(name,
new Kross::Api::ProxyFunction<INSTANCE, METHOD, RETURNOBJ, ARG1OBJ, ARG2OBJ, ARG3OBJ, ARG4OBJ>
(instance, method, arg1, arg2, arg3, arg4)
);
@@ -134,7 +134,7 @@ namespace Kross { namespace Api {
template<class RETURNOBJ, class ARG1OBJ, class ARG2OBJ, class ARG3OBJ, class INSTANCE, typename METHOD>
inline void addFunction3(const TQString& name, INSTANCE* instance, METHOD method, ARG1OBJ* arg1 = 0, ARG2OBJ* arg2 = 0, ARG3OBJ* arg3 = 0)
{
- m_functions.tqreplace(name,
+ m_functions.replace(name,
new Kross::Api::ProxyFunction<INSTANCE, METHOD, RETURNOBJ, ARG1OBJ, ARG2OBJ, ARG3OBJ>
(instance, method, arg1, arg2, arg3)
);
@@ -144,7 +144,7 @@ namespace Kross { namespace Api {
template<class RETURNOBJ, class ARG1OBJ, class ARG2OBJ, class INSTANCE, typename METHOD>
inline void addFunction2(const TQString& name, INSTANCE* instance, METHOD method, ARG1OBJ* arg1 = 0, ARG2OBJ* arg2 = 0)
{
- m_functions.tqreplace(name,
+ m_functions.replace(name,
new Kross::Api::ProxyFunction<INSTANCE, METHOD, RETURNOBJ, ARG1OBJ, ARG2OBJ>
(instance, method, arg1, arg2)
);
@@ -154,7 +154,7 @@ namespace Kross { namespace Api {
template<class RETURNOBJ, class ARG1OBJ, class INSTANCE, typename METHOD>
inline void addFunction1(const TQString& name, INSTANCE* instance, METHOD method, ARG1OBJ* arg1 = 0)
{
- m_functions.tqreplace(name,
+ m_functions.replace(name,
new Kross::Api::ProxyFunction<INSTANCE, METHOD, RETURNOBJ, ARG1OBJ>
(instance, method, arg1)
);
@@ -164,7 +164,7 @@ namespace Kross { namespace Api {
template<class RETURNOBJ, class INSTANCE, typename METHOD>
inline void addFunction0(const TQString& name, INSTANCE* instance, METHOD method)
{
- m_functions.tqreplace(name,
+ m_functions.replace(name,
new Kross::Api::ProxyFunction<INSTANCE, METHOD, RETURNOBJ>
(instance, method)
);
@@ -177,7 +177,7 @@ namespace Kross { namespace Api {
*/
bool isAFunction(const TQString & name) const
{
- return m_functions.tqcontains(name);
+ return m_functions.contains(name);
}
/**
diff --git a/lib/kross/api/eventsignal.cpp b/lib/kross/api/eventsignal.cpp
index c3e94620..e3a8e54f 100644
--- a/lib/kross/api/eventsignal.cpp
+++ b/lib/kross/api/eventsignal.cpp
@@ -54,7 +54,7 @@ Object::Ptr EventSignal::call(const TQString& /*name*/, KSharedPtr<List> argumen
if(n.startsWith("2")) // Remove prefix of SIGNAL-macros
n.remove(0,1);
- int signalid = m_sender->tqmetaObject()->tqfindSignal(n.latin1(), false);
+ int signalid = m_sender->tqmetaObject()->findSignal(n.latin1(), false);
if(signalid < 0)
throw new Exception(TQString("No such signal '%1'.").tqarg(n));
diff --git a/lib/kross/api/eventslot.cpp b/lib/kross/api/eventslot.cpp
index fed92ea0..fd566d31 100644
--- a/lib/kross/api/eventslot.cpp
+++ b/lib/kross/api/eventslot.cpp
@@ -54,7 +54,7 @@ Object::Ptr EventSlot::call(const TQString& /*name*/, List::Ptr arguments)
if(n.startsWith("1")) // Remove prefix of SLOT-macros
n.remove(0,1);
- int slotid = m_receiver->tqmetaObject()->tqfindSlot(n.latin1(), false);
+ int slotid = m_receiver->tqmetaObject()->findSlot(n.latin1(), false);
if(slotid < 0)
throw Exception::Ptr( new Exception(TQString("No such slot '%1'.").tqarg(n)) );
@@ -69,8 +69,8 @@ Object::Ptr EventSlot::call(const TQString& /*name*/, List::Ptr arguments)
TQCString EventSlot::getSlot(const TQCString& signal)
{
TQString signature = TQString(signal).mid(1);
- int startpos = signature.tqfind("(");
- int endpos = signature.tqfindRev(")");
+ int startpos = signature.find("(");
+ int endpos = signature.findRev(")");
if(startpos < 0 || startpos > endpos) {
krosswarning( TQString("EventSlot::getSlot(%1) Invalid signal.").tqarg(signal) );
return TQCString();
diff --git a/lib/kross/api/interpreter.cpp b/lib/kross/api/interpreter.cpp
index c6796e1f..8d266930 100644
--- a/lib/kross/api/interpreter.cpp
+++ b/lib/kross/api/interpreter.cpp
@@ -71,7 +71,7 @@ const TQStringList InterpreterInfo::getMimeTypes()
bool InterpreterInfo::hasOption(const TQString& key)
{
- return m_options.tqcontains(key);
+ return m_options.contains(key);
}
InterpreterInfo::Option* InterpreterInfo::getOption(const TQString name)
diff --git a/lib/kross/api/qtobject.cpp b/lib/kross/api/qtobject.cpp
index 2aa8f408..243f0503 100644
--- a/lib/kross/api/qtobject.cpp
+++ b/lib/kross/api/qtobject.cpp
@@ -90,8 +90,8 @@ TQObject* QtObject::getObject()
TQUObject* QtObject::toTQUObject(const TQString& signature, List::Ptr arguments)
{
- int startpos = signature.tqfind("(");
- int endpos = signature.tqfindRev(")");
+ int startpos = signature.find("(");
+ int endpos = signature.findRev(")");
if(startpos < 0 || startpos > endpos)
throw Exception::Ptr( new Exception(TQString("Invalid TQt signal or slot signature '%1'").tqarg(signature)) );
@@ -112,7 +112,7 @@ TQUObject* QtObject::toTQUObject(const TQString& signature, List::Ptr arguments)
// Fill parameters.
uint argcount = arguments ? arguments->count() : 0;
for(uint i = 0; i < paramcount; i++) {
- if(paramlist[i].tqfind(TQSTRING_OBJECT_NAME_STRING) >= 0) {
+ if(paramlist[i].find(TQSTRING_OBJECT_NAME_STRING) >= 0) {
const TQString s = (argcount > i) ? Variant::toString(arguments->item(i)) : TQString();
//krossdebug(TQString("EventSlot::toTQUObject s=%1").tqarg(s));
static_TQUType_TQString.set( &(uo[i + 1]), s );
@@ -135,7 +135,7 @@ Kross::Api::Object::Ptr QtObject::propertyNames(Kross::Api::List::Ptr)
Kross::Api::Object::Ptr QtObject::hasProperty(Kross::Api::List::Ptr args)
{
return new Kross::Api::Variant(
- m_object->tqmetaObject()->tqfindProperty(Kross::Api::Variant::toString(args->item(0)).latin1(), false));
+ m_object->tqmetaObject()->findProperty(Kross::Api::Variant::toString(args->item(0)).latin1(), false));
}
Kross::Api::Object::Ptr QtObject::getProperty(Kross::Api::List::Ptr args)
@@ -164,7 +164,7 @@ Kross::Api::Object::Ptr QtObject::slotNames(Kross::Api::List::Ptr)
Kross::Api::Object::Ptr QtObject::hasSlot(Kross::Api::List::Ptr args)
{
return new Kross::Api::Variant(
- bool(m_object->tqmetaObject()->slotNames(false).tqfind(
+ bool(m_object->tqmetaObject()->slotNames(false).find(
Kross::Api::Variant::toString(args->item(0)).latin1()
) != -1));
}
@@ -173,7 +173,7 @@ Kross::Api::Object::Ptr QtObject::callSlot(Kross::Api::List::Ptr args)
{
//TODO just call the child event ?!
TQString name = Kross::Api::Variant::toString(args->item(0));
- int slotid = m_object->tqmetaObject()->tqfindSlot(name.latin1(), false);
+ int slotid = m_object->tqmetaObject()->findSlot(name.latin1(), false);
if(slotid < 0)
throw Exception::Ptr( new Exception(TQString("No such slot '%1'.").tqarg(name)) );
@@ -193,7 +193,7 @@ Kross::Api::Object::Ptr QtObject::signalNames(Kross::Api::List::Ptr)
Kross::Api::Object::Ptr QtObject::hasSignal(Kross::Api::List::Ptr args)
{
return new Kross::Api::Variant(
- bool(m_object->tqmetaObject()->signalNames(false).tqfind(
+ bool(m_object->tqmetaObject()->signalNames(false).find(
Kross::Api::Variant::toString(args->item(0)).latin1()
) != -1));
}
@@ -201,7 +201,7 @@ Kross::Api::Object::Ptr QtObject::hasSignal(Kross::Api::List::Ptr args)
Kross::Api::Object::Ptr QtObject::emitSignal(Kross::Api::List::Ptr args)
{
TQString name = Kross::Api::Variant::toString(args->item(0));
- int signalid = m_object->tqmetaObject()->tqfindSignal(name.latin1(), false);
+ int signalid = m_object->tqmetaObject()->findSignal(name.latin1(), false);
if(signalid < 0)
throw Exception::Ptr( new Exception(TQString("No such signal '%1'.").tqarg(name)) );
m_object->qt_invoke(signalid, 0); //TODO convert Kross::Api::List::Ptr => TQUObject*