summaryrefslogtreecommitdiffstats
path: root/kdnssd/kdedmodule
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
commit47c8a359c5276062c4bc17f0e82410f29081b502 (patch)
tree2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kdnssd/kdedmodule
parent6f82532777a35e0e60bbd2b290b2e93e646f349b (diff)
downloadtdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz
tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdnssd/kdedmodule')
-rw-r--r--kdnssd/kdedmodule/dnssdwatcher.cpp14
-rw-r--r--kdnssd/kdedmodule/dnssdwatcher.h14
-rw-r--r--kdnssd/kdedmodule/watcher.cpp16
-rw-r--r--kdnssd/kdedmodule/watcher.h10
4 files changed, 27 insertions, 27 deletions
diff --git a/kdnssd/kdedmodule/dnssdwatcher.cpp b/kdnssd/kdedmodule/dnssdwatcher.cpp
index a7eb256f..7e1ef6d2 100644
--- a/kdnssd/kdedmodule/dnssdwatcher.cpp
+++ b/kdnssd/kdedmodule/dnssdwatcher.cpp
@@ -26,7 +26,7 @@
#include "watcher.h"
-DNSSDWatcher::DNSSDWatcher(const QCString& obj)
+DNSSDWatcher::DNSSDWatcher(const TQCString& obj)
: KDEDModule(obj)
{
connectDCOPSignal("","KDirNotify","enteredDirectory(KURL)","enteredDirectory(KURL)",false);
@@ -34,12 +34,12 @@ DNSSDWatcher::DNSSDWatcher(const QCString& obj)
watchers.setAutoDelete(true);
}
-QStringList DNSSDWatcher::watchedDirectories()
+TQStringList DNSSDWatcher::watchedDirectories()
{
//TODO
// return watchers.keys();
- QStringList keys;
- for (QDictIterator<Watcher> it(watchers) ; it.current(); ++it ) {
+ TQStringList keys;
+ for (TQDictIterator<Watcher> it(watchers) ; it.current(); ++it ) {
keys << it.currentKey();
kdDebug() << it.currentKey() << " " << (*it)->refcount << "\n";
}
@@ -48,7 +48,7 @@ return keys;
// from ioslave
-void DNSSDWatcher::dissect(const KURL& url,QString& name,QString& type,QString& domain)
+void DNSSDWatcher::dissect(const KURL& url,TQString& name,TQString& type,TQString& domain)
{
type = url.path().section("/",1,1);
domain = url.host();
@@ -76,7 +76,7 @@ void DNSSDWatcher::leftDirectory(const KURL& dir)
void DNSSDWatcher::createNotifier(const KURL& url)
{
- QString domain,type,name;
+ TQString domain,type,name;
dissect(url,name,type,domain);
if (type.isEmpty()) type = DNSSD::ServiceBrowser::AllServices;
Watcher *w = new Watcher(type,domain);
@@ -84,7 +84,7 @@ void DNSSDWatcher::createNotifier(const KURL& url)
}
extern "C" {
- KDE_EXPORT KDEDModule *create_dnssdwatcher(const QCString &obj)
+ KDE_EXPORT KDEDModule *create_dnssdwatcher(const TQCString &obj)
{
KGlobal::locale()->insertCatalogue("dnssdwatcher");
return new DNSSDWatcher(obj);
diff --git a/kdnssd/kdedmodule/dnssdwatcher.h b/kdnssd/kdedmodule/dnssdwatcher.h
index eb2d7092..2baea9fe 100644
--- a/kdnssd/kdedmodule/dnssdwatcher.h
+++ b/kdnssd/kdedmodule/dnssdwatcher.h
@@ -19,10 +19,10 @@
#ifndef _DNSSDWATCHER_H_
#define _DNSSDWATCHER_H_
-#include <qdict.h>
+#include <tqdict.h>
#include <kdedmodule.h>
-#include <qstring.h>
-#include <qstringlist.h>
+#include <tqstring.h>
+#include <tqstringlist.h>
#include <kurl.h>
class Watcher;
@@ -31,18 +31,18 @@ class DNSSDWatcher : public KDEDModule
Q_OBJECT
K_DCOP
public:
- DNSSDWatcher(const QCString& obj);
+ DNSSDWatcher(const TQCString& obj);
k_dcop:
- QStringList watchedDirectories();
+ TQStringList watchedDirectories();
void enteredDirectory(const KURL& dir);
void leftDirectory(const KURL& dir);
private:
- QDict<Watcher> watchers;
+ TQDict<Watcher> watchers;
void createNotifier(const KURL& url);
- void dissect(const KURL& url,QString& name,QString& type,QString& domain);
+ void dissect(const KURL& url,TQString& name,TQString& type,TQString& domain);
};
diff --git a/kdnssd/kdedmodule/watcher.cpp b/kdnssd/kdedmodule/watcher.cpp
index d4dcc95a..f6b7a973 100644
--- a/kdnssd/kdedmodule/watcher.cpp
+++ b/kdnssd/kdedmodule/watcher.cpp
@@ -21,20 +21,20 @@
#include <kdebug.h>
#include <kdirnotify_stub.h>
-#include <qstringlist.h>
+#include <tqstringlist.h>
-Watcher::Watcher(const QString& type, const QString& domain)
+Watcher::Watcher(const TQString& type, const TQString& domain)
: refcount(1), updateNeeded(false), m_type(type), m_domain(domain)
{
if (domain.isEmpty()) browser = new ServiceBrowser(type);
else browser = new ServiceBrowser(type,domain);
- connect(browser,SIGNAL(serviceAdded(DNSSD::RemoteService::Ptr)),
- SLOT(serviceAdded(DNSSD::RemoteService::Ptr)));
- connect(browser,SIGNAL(serviceRemoved(DNSSD::RemoteService::Ptr)),
- SLOT(serviceRemoved(DNSSD::RemoteService::Ptr)));
- connect(browser,SIGNAL(finished()),SLOT(finished()));
+ connect(browser,TQT_SIGNAL(serviceAdded(DNSSD::RemoteService::Ptr)),
+ TQT_SLOT(serviceAdded(DNSSD::RemoteService::Ptr)));
+ connect(browser,TQT_SIGNAL(serviceRemoved(DNSSD::RemoteService::Ptr)),
+ TQT_SLOT(serviceRemoved(DNSSD::RemoteService::Ptr)));
+ connect(browser,TQT_SIGNAL(finished()),TQT_SLOT(finished()));
browser->startBrowse();
}
@@ -59,7 +59,7 @@ void Watcher::finished()
KDirNotify_stub st("*","*");
kdDebug() << "Finished for " << m_type << "@" << m_domain << "\n";
if (updateNeeded || removed.count()) {
- QString url = "zeroconf:/";
+ TQString url = "zeroconf:/";
if (!m_domain.isEmpty()) url+="/"+m_domain+"/";
if (m_type!=ServiceBrowser::AllServices) url+=m_type;
kdDebug() << "Sending update: " << url << "\n";
diff --git a/kdnssd/kdedmodule/watcher.h b/kdnssd/kdedmodule/watcher.h
index 84e9104e..64c5635c 100644
--- a/kdnssd/kdedmodule/watcher.h
+++ b/kdnssd/kdedmodule/watcher.h
@@ -19,7 +19,7 @@
#ifndef _WATCHER_H_
#define _WATCHER_H_
-#include <qstring.h>
+#include <tqstring.h>
#include <dnssd/servicebrowser.h>
#include <dnssd/remoteservice.h>
@@ -29,16 +29,16 @@ class Watcher : public QObject
{
Q_OBJECT
public:
- Watcher(const QString& type, const QString& domain);
+ Watcher(const TQString& type, const TQString& domain);
~Watcher();
unsigned int refcount;
private:
ServiceBrowser* browser;
bool updateNeeded;
- QString m_type;
- QString m_domain;
- QValueList<DNSSD::RemoteService::Ptr> removed;
+ TQString m_type;
+ TQString m_domain;
+ TQValueList<DNSSD::RemoteService::Ptr> removed;
private slots:
void serviceRemoved(DNSSD::RemoteService::Ptr srv);