rename the following methods:

tqfind find
tqreplace replace
tqcontains contains


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/dependencies/dbus-1-tqt@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 13 years ago
parent c8d1884b41
commit f32d0d5fd0

@ -65,7 +65,7 @@ modification follow.
GNU GENERAL PUBLIC LICENSE GNU GENERAL PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. This License applies to any program or other work which tqcontains 0. This License applies to any program or other work which contains
a notice placed by the copyright holder saying it may be distributed a notice placed by the copyright holder saying it may be distributed
under the terms of this General Public License. The "Program", below, under the terms of this General Public License. The "Program", below,
refers to any such program or work, and a "work based on the Program" refers to any such program or work, and a "work based on the Program"
@ -102,7 +102,7 @@ above, provided that you also meet all of these conditions:
stating that you changed the files and the date of any change. stating that you changed the files and the date of any change.
b) You must cause any work that you distribute or publish, that in b) You must cause any work that you distribute or publish, that in
whole or in part tqcontains or is derived from the Program or any whole or in part contains or is derived from the Program or any
part thereof, to be licensed as a whole at no charge to all third part thereof, to be licensed as a whole at no charge to all third
parties under the terms of this License. parties under the terms of this License.
@ -160,7 +160,7 @@ Sections 1 and 2 above provided that you also do one of the following:
The source code for a work means the preferred form of the work for The source code for a work means the preferred form of the work for
making modifications to it. For an executable work, complete source making modifications to it. For an executable work, complete source
code means all the source code for all modules it tqcontains, plus any code means all the source code for all modules it contains, plus any
associated interface definition files, plus the scripts used to associated interface definition files, plus the scripts used to
control compilation and installation of the executable. However, as a control compilation and installation of the executable. However, as a
special exception, the source code distributed need not include special exception, the source code distributed need not include

@ -17,7 +17,7 @@ reconfiguring, and a file `config.log' containing compiler output
to figure out how `configure' could check whether to do them, and mail to figure out how `configure' could check whether to do them, and mail
diffs or instructions to the address given in the `README' so they can diffs or instructions to the address given in the `README' so they can
be considered for the next release. If at some point `config.cache' be considered for the next release. If at some point `config.cache'
tqcontains results you don't want to keep, you may remove or edit it. contains results you don't want to keep, you may remove or edit it.
The file `configure.in' is used to create `configure' by a program The file `configure.in' is used to create `configure' by a program
called `autoconf'. You only need `configure.in' if you want to change called `autoconf'. You only need `configure.in' if you want to change
@ -37,7 +37,7 @@ The simplest way to compile this package is:
2. Type `gmake' to compile the package. Or if you're using a Linux 2. Type `gmake' to compile the package. Or if you're using a Linux
powered machine, or if make is GNU make, type `make'. You can powered machine, or if make is GNU make, type `make'. You can
check with make --version. KDE requires GNU make to build, if check with make --version. KDE requires GNU make to build, if
gmake is appropriate, tqreplace any instance below of make with gmake. gmake is appropriate, replace any instance below of make with gmake.
It will give output similar to: It will give output similar to:
#make --version #make --version
GNU Make version 3.78.1, by Richard Stallman and Roland McGrath. GNU Make version 3.78.1, by Richard Stallman and Roland McGrath.
@ -119,7 +119,7 @@ is something like `gnu-as' or `x' (for the X Window System). The
package recognizes. package recognizes.
For packages that use the X Window System, `configure' can usually For packages that use the X Window System, `configure' can usually
tqfind the X include and library files automatically, but if it doesn't, find the X include and library files automatically, but if it doesn't,
you can use the `configure' options `--x-includes=DIR' and you can use the `configure' options `--x-includes=DIR' and
`--x-libraries=DIR' to specify their locations. `--x-libraries=DIR' to specify their locations.

@ -42,7 +42,7 @@ OptionMap parseOptions(int argc, char** argv);
bool checkForOption(const OptionMap& options, const TQString& option) bool checkForOption(const OptionMap& options, const TQString& option)
{ {
return options.tqfind(option) != options.end(); return options.find(option) != options.end();
} }
int main(int argc, char** argv) int main(int argc, char** argv)
@ -336,7 +336,7 @@ int main(int argc, char** argv)
exit(3); exit(3);
} }
nodeClassName.tqreplace('/', "_"); nodeClassName.replace('/', "_");
} }
TQStringList nameParts = TQStringList::split("::", nodeClassName); TQStringList nameParts = TQStringList::split("::", nodeClassName);
@ -451,7 +451,7 @@ void usage()
bool testAndSetOption(OptionMap& options, const TQString& option, const TQString& value) bool testAndSetOption(OptionMap& options, const TQString& option, const TQString& value)
{ {
OptionMap::iterator it = options.tqfind(option); OptionMap::iterator it = options.find(option);
if (it == options.end()) if (it == options.end())
{ {
options.insert(option, value); options.insert(option, value);

@ -133,8 +133,8 @@ static bool parseDBusSignature(const TQString& signature, Argument& argument)
} }
else if (signature.startsWith("a{")) else if (signature.startsWith("a{"))
{ {
int from = signature.tqfind("{"); int from = signature.find("{");
int to = signature.tqfindRev("}"); int to = signature.findRev("}");
if (from == -1 || to == -1 || (to - from - 1) < 2) return false; if (from == -1 || to == -1 || (to - from - 1) < 2) return false;
TQString dictSignature = signature.mid(from + 1, (to - from - 1)); TQString dictSignature = signature.mid(from + 1, (to - from - 1));
@ -600,8 +600,8 @@ bool MethodGenerator::extractMethods(const TQDomElement& interfaceElement,
{ {
Property property; Property property;
property.name = element.attribute("name"); property.name = element.attribute("name");
property.read = element.attribute("access").tqfind("read") != -1; property.read = element.attribute("access").find("read") != -1;
property.write = element.attribute("access").tqfind("write") != -1; property.write = element.attribute("access").find("write") != -1;
TQString annotation = TQString annotation =
propertyAnnotations[TQString("Property%1").arg(propertyCount)]; propertyAnnotations[TQString("Property%1").arg(propertyCount)];
@ -754,7 +754,7 @@ void MethodGenerator::writeMethodCall(const Class& classData,
if (method.async) if (method.async)
{ {
stream << " int _asyncCallId = 0;" << endl; stream << " int _asyncCallId = 0;" << endl;
stream << " while (m_asyncCalls.tqfind(_asyncCallId) != m_asyncCalls.end())" stream << " while (m_asyncCalls.find(_asyncCallId) != m_asyncCalls.end())"
<< endl; << endl;
stream << " {" << endl; stream << " {" << endl;
stream << " ++_asyncCallId;" << endl; stream << " ++_asyncCallId;" << endl;
@ -976,12 +976,12 @@ void MethodGenerator::writeInterfaceAsyncReplyHandler(const Class& classData,
stream << endl; stream << endl;
stream << "{" << endl; stream << "{" << endl;
stream << " TQMap<int, TQT_DBusMessage>::iterator tqfindIt = m_asyncCalls.tqfind(asyncCallId);" << endl; stream << " TQMap<int, TQT_DBusMessage>::iterator findIt = m_asyncCalls.find(asyncCallId);" << endl;
stream << " if (tqfindIt == m_asyncCalls.end()) return;" << endl; stream << " if (findIt == m_asyncCalls.end()) return;" << endl;
stream << endl; stream << endl;
stream << " TQT_DBusMessage call = tqfindIt.data();" << endl; stream << " TQT_DBusMessage call = findIt.data();" << endl;
stream << " m_asyncCalls.erase(tqfindIt);" << endl; stream << " m_asyncCalls.erase(findIt);" << endl;
stream << endl; stream << endl;
stream << " TQT_DBusMessage reply = TQT_DBusMessage::methodReply(call);" stream << " TQT_DBusMessage reply = TQT_DBusMessage::methodReply(call);"
@ -1029,12 +1029,12 @@ void MethodGenerator::writeInterfaceAsyncReplyHandler(const Class& classData,
stream << "{" << endl; stream << "{" << endl;
stream << " TQMap<int, TQT_DBusMessage>::iterator tqfindIt = m_asyncCalls.tqfind(asyncCallId);" << endl; stream << " TQMap<int, TQT_DBusMessage>::iterator findIt = m_asyncCalls.find(asyncCallId);" << endl;
stream << " if (tqfindIt == m_asyncCalls.end()) return;" << endl; stream << " if (findIt == m_asyncCalls.end()) return;" << endl;
stream << endl; stream << endl;
stream << " TQT_DBusMessage call = tqfindIt.data();" << endl; stream << " TQT_DBusMessage call = findIt.data();" << endl;
stream << " m_asyncCalls.erase(tqfindIt);" << endl; stream << " m_asyncCalls.erase(findIt);" << endl;
stream << endl; stream << endl;
stream << " TQT_DBusMessage reply = TQT_DBusMessage::methodError(call, error);" stream << " TQT_DBusMessage reply = TQT_DBusMessage::methodError(call, error);"
@ -1544,12 +1544,12 @@ void MethodGenerator::writeProxyAsyncReplyHandler(const Class& classData,
<< "::slotHandleAsyncReply(int asyncCallId, const TQT_DBusMessage& message)" << endl; << "::slotHandleAsyncReply(int asyncCallId, const TQT_DBusMessage& message)" << endl;
stream << "{" << endl; stream << "{" << endl;
stream << " TQMap<int, TQString>::iterator tqfindIt = " stream << " TQMap<int, TQString>::iterator findIt = "
<< "m_asyncCalls.tqfind(asyncCallId);" << endl; << "m_asyncCalls.find(asyncCallId);" << endl;
stream << " if (tqfindIt == m_asyncCalls.end()) return;" << endl; stream << " if (findIt == m_asyncCalls.end()) return;" << endl;
stream << endl; stream << endl;
stream << " const TQString signalName = tqfindIt.data();" << endl; stream << " const TQString signalName = findIt.data();" << endl;
stream << " m_asyncCalls.erase(tqfindIt);" << endl; stream << " m_asyncCalls.erase(findIt);" << endl;
stream << endl; stream << endl;
TQValueList<Method>::const_iterator it = classData.asyncReplySignals.begin(); TQValueList<Method>::const_iterator it = classData.asyncReplySignals.begin();
@ -1722,12 +1722,12 @@ void MethodGenerator::writeNodeMethods(const Class& classData,
stream << "bool " << classData.name stream << "bool " << classData.name
<< "::handleMethodCall(const TQT_DBusMessage& message)" << endl; << "::handleMethodCall(const TQT_DBusMessage& message)" << endl;
stream << "{" << endl; stream << "{" << endl;
stream << " TQMap<TQString, TQT_DBusObjectBase*>::iterator tqfindIt = " stream << " TQMap<TQString, TQT_DBusObjectBase*>::iterator findIt = "
<< "m_private->interfaces.tqfind(message.interface());" << endl; << "m_private->interfaces.find(message.interface());" << endl;
stream << " if (tqfindIt == m_private->interfaces.end()) return false;" stream << " if (findIt == m_private->interfaces.end()) return false;"
<< endl; << endl;
stream << endl; stream << endl;
stream << " return delegateMethodCall(message, tqfindIt.data());" << endl; stream << " return delegateMethodCall(message, findIt.data());" << endl;
stream << "}" << endl; stream << "}" << endl;
stream << endl; stream << endl;

@ -66,7 +66,7 @@ TQT_DBusConnectionPrivate *TQT_DBusConnectionManager::connection(const TQString
if (name == TQString::tqfromLatin1(TQT_DBusConnection::default_connection_name)) if (name == TQString::tqfromLatin1(TQT_DBusConnection::default_connection_name))
return default_connection; return default_connection;
ConnectionHash::const_iterator it = connectionHash.tqfind(name); ConnectionHash::const_iterator it = connectionHash.find(name);
return (it != connectionHash.end() ? it.data() : 0); return (it != connectionHash.end() ? it.data() : 0);
} }
@ -78,7 +78,7 @@ void TQT_DBusConnectionManager::removeConnection(const TQString &name)
d = default_connection; d = default_connection;
default_connection = 0; default_connection = 0;
} else { } else {
ConnectionHash::iterator it = connectionHash.tqfind(name); ConnectionHash::iterator it = connectionHash.find(name);
if (it == connectionHash.end()) if (it == connectionHash.end())
return; return;
@ -334,7 +334,7 @@ bool TQT_DBusConnection::registerObject(const TQString& path, TQT_DBusObjectBase
if (!d || !d->connection || !object || path.isEmpty()) if (!d || !d->connection || !object || path.isEmpty())
return false; return false;
TQT_DBusConnectionPrivate::ObjectMap::const_iterator it = d->registeredObjects.tqfind(path); TQT_DBusConnectionPrivate::ObjectMap::const_iterator it = d->registeredObjects.find(path);
if (it != d->registeredObjects.end()) if (it != d->registeredObjects.end())
return false; return false;
@ -348,7 +348,7 @@ void TQT_DBusConnection::unregisterObject(const TQString &path)
if (!d || !d->connection || path.isEmpty()) if (!d || !d->connection || path.isEmpty())
return; return;
TQT_DBusConnectionPrivate::ObjectMap::iterator it = d->registeredObjects.tqfind(path); TQT_DBusConnectionPrivate::ObjectMap::iterator it = d->registeredObjects.find(path);
if (it == d->registeredObjects.end()) if (it == d->registeredObjects.end())
return ; return ;

@ -195,7 +195,7 @@ public:
*/ */
SystemBus, SystemBus,
// TODO tqfind out about ActivationBus purpose // TODO find out about ActivationBus purpose
ActivationBus ActivationBus
}; };
@ -560,7 +560,7 @@ public:
* *
* Equivalent to calling addConnection(SessionBus); * Equivalent to calling addConnection(SessionBus);
* *
* @return a connection handle. Check isConnected() to tqfind out if the * @return a connection handle. Check isConnected() to find out if the
* connection attempt has been successfull * connection attempt has been successfull
* *
* @see addConnection(BusType,const TQString&); * @see addConnection(BusType,const TQString&);
@ -575,7 +575,7 @@ public:
* *
* Equivalent to calling addConnection(SystemBus); * Equivalent to calling addConnection(SystemBus);
* *
* @return a connection handle. Check isConnected() to tqfind out if the * @return a connection handle. Check isConnected() to find out if the
* connection attempt has been successfull * connection attempt has been successfull
* *
* @see addConnection(BusType,const TQString&); * @see addConnection(BusType,const TQString&);
@ -610,7 +610,7 @@ public:
* @param type the #BusType of the bus to connect to * @param type the #BusType of the bus to connect to
* @param name the name to use for TQT_DBusConnection's connection sharing * @param name the name to use for TQT_DBusConnection's connection sharing
* *
* @return a connection handle. Check isConnected() to tqfind out if the * @return a connection handle. Check isConnected() to find out if the
* connection attempt has been successfull * connection attempt has been successfull
* *
* @see closeConnection() * @see closeConnection()
@ -631,7 +631,7 @@ public:
* socket address * socket address
* @param name the name to use for TQT_DBusConnection's connection sharing * @param name the name to use for TQT_DBusConnection's connection sharing
* *
* @return a connection handle. Check isConnected() to tqfind out if the * @return a connection handle. Check isConnected() to find out if the
* connection attempt has been successfull * connection attempt has been successfull
* *
* @see closeConnection() * @see closeConnection()

@ -330,7 +330,7 @@ public:
bool operator!=(const TQT_DBusData& other) const; bool operator!=(const TQT_DBusData& other) const;
/** /**
* @brief Checks whether the data object tqcontains a valid content * @brief Checks whether the data object contains a valid content
* *
* This is equal to checking type() for not being #Invalid * This is equal to checking type() for not being #Invalid
* *

@ -82,7 +82,7 @@ class TQT_DBusData;
* TQT_DBusDataConverter::convertFromTQT_DBusData<TQRect>(dbusData, rect); * TQT_DBusDataConverter::convertFromTQT_DBusData<TQRect>(dbusData, rect);
* @endcode * @endcode
* *
* @note The bindings library tqcontains the spezialisations for TQRect, TQPoint and TQSize. * @note The bindings library contains the spezialisations for TQRect, TQPoint and TQSize.
*/ */
class TQDBUS_EXPORT TQT_DBusDataConverter class TQDBUS_EXPORT TQT_DBusDataConverter
{ {

@ -107,7 +107,7 @@ static TQT_DBusError::ErrorType qDBusErrorTypeForName(const TQString& name)
if (errorTypesByName.isEmpty()) if (errorTypesByName.isEmpty())
qDBusErrorSetupNameMapping(); qDBusErrorSetupNameMapping();
ErrorNameMap::const_iterator it = errorTypesByName.tqfind(name); ErrorNameMap::const_iterator it = errorTypesByName.find(name);
if (it != errorTypesByName.end()) return it.data(); if (it != errorTypesByName.end()) return it.data();
return TQT_DBusError::UserDefined; return TQT_DBusError::UserDefined;

@ -229,7 +229,7 @@ public:
* @brief An type signature is not valid * @brief An type signature is not valid
* *
* A possible cause is a TQT_DBusVariant with an invalid signature, i.e. * A possible cause is a TQT_DBusVariant with an invalid signature, i.e.
* the transported signature is empty, tqcontains unknown type characters * the transported signature is empty, contains unknown type characters
* or has mismatched container enclosings. * or has mismatched container enclosings.
* *
* @note in case a service implementation wants to indicate that a method * @note in case a service implementation wants to indicate that a method

@ -145,7 +145,7 @@ static dbus_bool_t qDBusAddWatch(DBusWatch *watch, void *data)
} }
} }
// FIXME-QT4 d->watchers.insertMulti(fd, watcher); // FIXME-QT4 d->watchers.insertMulti(fd, watcher);
TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.tqfind(fd); TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.find(fd);
if (it == d->watchers.end()) if (it == d->watchers.end())
{ {
it = d->watchers.insert(fd, TQT_DBusConnectionPrivate::WatcherList()); it = d->watchers.insert(fd, TQT_DBusConnectionPrivate::WatcherList());
@ -165,7 +165,7 @@ static void qDBusRemoveWatch(DBusWatch *watch, void *data)
TQT_DBusConnectionPrivate *d = static_cast<TQT_DBusConnectionPrivate *>(data); TQT_DBusConnectionPrivate *d = static_cast<TQT_DBusConnectionPrivate *>(data);
int fd = dbus_watch_get_unix_fd(watch); int fd = dbus_watch_get_unix_fd(watch);
TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.tqfind(fd); TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.find(fd);
if (it != d->watchers.end()) if (it != d->watchers.end())
{ {
TQT_DBusConnectionPrivate::WatcherList& list = *it; TQT_DBusConnectionPrivate::WatcherList& list = *it;
@ -207,7 +207,7 @@ static void qDBusToggleWatch(DBusWatch *watch, void *data)
TQT_DBusConnectionPrivate *d = static_cast<TQT_DBusConnectionPrivate *>(data); TQT_DBusConnectionPrivate *d = static_cast<TQT_DBusConnectionPrivate *>(data);
int fd = dbus_watch_get_unix_fd(watch); int fd = dbus_watch_get_unix_fd(watch);
TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.tqfind(fd); TQT_DBusConnectionPrivate::WatcherHash::iterator it = d->watchers.find(fd);
if (it != d->watchers.end()) { if (it != d->watchers.end()) {
TQT_DBusConnectionPrivate::WatcherList& list = *it; TQT_DBusConnectionPrivate::WatcherList& list = *it;
for (TQT_DBusConnectionPrivate::WatcherList::iterator wit = list.begin(); wit != list.end(); for (TQT_DBusConnectionPrivate::WatcherList::iterator wit = list.begin(); wit != list.end();
@ -357,7 +357,7 @@ void TQT_DBusConnectionPrivate::bindToApplication()
void TQT_DBusConnectionPrivate::socketRead(int fd) void TQT_DBusConnectionPrivate::socketRead(int fd)
{ {
// FIXME-QT4 TQHashIterator<int, TQT_DBusConnectionPrivate::Watcher> it(watchers); // FIXME-QT4 TQHashIterator<int, TQT_DBusConnectionPrivate::Watcher> it(watchers);
WatcherHash::const_iterator it = watchers.tqfind(fd); WatcherHash::const_iterator it = watchers.find(fd);
if (it != watchers.end()) { if (it != watchers.end()) {
const WatcherList& list = *it; const WatcherList& list = *it;
for (WatcherList::const_iterator wit = list.begin(); wit != list.end(); ++wit) { for (WatcherList::const_iterator wit = list.begin(); wit != list.end(); ++wit) {
@ -374,7 +374,7 @@ void TQT_DBusConnectionPrivate::socketRead(int fd)
void TQT_DBusConnectionPrivate::socketWrite(int fd) void TQT_DBusConnectionPrivate::socketWrite(int fd)
{ {
// FIXME-QT4 TQHashIterator<int, TQT_DBusConnectionPrivate::Watcher> it(watchers); // FIXME-QT4 TQHashIterator<int, TQT_DBusConnectionPrivate::Watcher> it(watchers);
WatcherHash::const_iterator it = watchers.tqfind(fd); WatcherHash::const_iterator it = watchers.find(fd);
if (it != watchers.end()) { if (it != watchers.end()) {
const WatcherList& list = *it; const WatcherList& list = *it;
for (WatcherList::const_iterator wit = list.begin(); wit != list.end(); ++wit) { for (WatcherList::const_iterator wit = list.begin(); wit != list.end(); ++wit) {
@ -466,7 +466,7 @@ bool TQT_DBusConnectionPrivate::handleObjectCall(DBusMessage *message)
{ {
TQT_DBusMessage msg = TQT_DBusMessage::fromDBusMessage(message); TQT_DBusMessage msg = TQT_DBusMessage::fromDBusMessage(message);
ObjectMap::iterator it = registeredObjects.tqfind(msg.path()); ObjectMap::iterator it = registeredObjects.find(msg.path());
if (it == registeredObjects.end()) if (it == registeredObjects.end())
return false; return false;
@ -559,7 +559,7 @@ static void qDBusResultReceived(DBusPendingCall *pending, void *user_data)
{ {
//qDebug("Pending Call Result received"); //qDebug("Pending Call Result received");
TQT_DBusConnectionPrivate* d = reinterpret_cast<TQT_DBusConnectionPrivate*>(user_data); TQT_DBusConnectionPrivate* d = reinterpret_cast<TQT_DBusConnectionPrivate*>(user_data);
TQT_DBusConnectionPrivate::PendingCallMap::iterator it = d->pendingCalls.tqfind(pending); TQT_DBusConnectionPrivate::PendingCallMap::iterator it = d->pendingCalls.find(pending);
DBusMessage *dbusReply = dbus_pending_call_steal_reply(pending); DBusMessage *dbusReply = dbus_pending_call_steal_reply(pending);

@ -53,7 +53,7 @@ TQT_DBusObjectPath TQT_DBusObjectPath::parentNode() const
{ {
if (length() == 1) return TQT_DBusObjectPath(); if (length() == 1) return TQT_DBusObjectPath();
int index = tqfindRev('/'); int index = findRev('/');
if (index == -1) return TQT_DBusObjectPath(); if (index == -1) return TQT_DBusObjectPath();

Loading…
Cancel
Save