diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-15 15:50:21 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-15 15:50:21 -0600 |
commit | 3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12 (patch) | |
tree | 89de88213bd261e4ccaade899ab2d6ec34b3a5a7 /kmobile/kioslave | |
parent | 1dad5f662a09dfc5cc041caffe0f674044a4dcec (diff) | |
download | tdepim-3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12.tar.gz tdepim-3ca10fd9a2dc631429d3b5d5c5e42a7d211d5a12.zip |
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'kmobile/kioslave')
-rw-r--r-- | kmobile/kioslave/kio_mobile.cpp | 80 | ||||
-rw-r--r-- | kmobile/kioslave/mimetypes/mobile_device.desktop | 2 |
2 files changed, 41 insertions, 41 deletions
diff --git a/kmobile/kioslave/kio_mobile.cpp b/kmobile/kioslave/kio_mobile.cpp index ed570196d..d8216bcd3 100644 --- a/kmobile/kioslave/kio_mobile.cpp +++ b/kmobile/kioslave/kio_mobile.cpp @@ -78,13 +78,13 @@ KMobileProtocol::~KMobileProtocol() } /* - * getDeviceAndRessource("mobile:/<tqdevicename>/<resource>/...") - split + * getDeviceAndRessource("mobile:/<devicename>/<resource>/...") - split */ int KMobileProtocol::getDeviceAndRessource(const TQString &_path, TQString &devName, TQString &resource, TQString &devPath, KMobileDevice::Capabilities &devCaps) { -// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").tqarg(_path); +// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").arg(_path); TQStringList path = TQStringList::split('/', _path, false); devName = resource = devPath = TQString(); @@ -140,7 +140,7 @@ void createDirEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& addAtom(entry, KIO::UDS_URL, 0, url); addAtom(entry, KIO::UDS_USER, 0, getenv("USER")); addAtom(entry, KIO::UDS_GROUP, 0, getenv("USER")); - PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").tqarg(name).tqarg(mime).tqarg(url); + PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").arg(name).arg(mime).arg(url); // addAtom(entry, KIO::UDS_SIZE, 0); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); } @@ -159,7 +159,7 @@ void createFileEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& addAtom(entry, KIO::UDS_MIME_TYPE, 0, mime); if (size) addAtom(entry, KIO::UDS_SIZE, size); addAtom(entry, KIO::UDS_GUESSED_MIME_TYPE, 0, mime); - PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").tqarg(name).tqarg(size).tqarg(mime); + PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").arg(name).arg(size).arg(mime); } @@ -169,7 +169,7 @@ void createFileEntry(KIO::UDSEntry& entry, const TQString& name, const TQString& void KMobileProtocol::get(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("get(%1)\n").tqarg(url.path()); + PRINT_DEBUG << TQString("get(%1)\n").arg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -227,16 +227,16 @@ void KMobileProtocol::get(const KURL &url) /* - * listRoot() - gives listing of all tqdevices + * listRoot() - gives listing of all devices */ void KMobileProtocol::listRoot(const KURL& url) { - PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").tqarg(url.path()).tqarg(url.protocol()); + PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").arg(url.path()).arg(url.protocol()); KIO::UDSEntry entry; - TQStringList tqdeviceNames = m_dev.tqdeviceNames(); - unsigned int dirs = tqdeviceNames.count(); + TQStringList deviceNames = m_dev.deviceNames(); + unsigned int dirs = deviceNames.count(); totalSize(dirs); int classMask = KMobileDevice::Unclassified; @@ -251,7 +251,7 @@ void KMobileProtocol::listRoot(const KURL& url) for (unsigned int i=0; i<dirs; i++) { - TQString devName = tqdeviceNames[i]; + TQString devName = deviceNames[i]; if (classMask != KMobileDevice::Unclassified && m_dev.classType(devName) != classMask) @@ -307,12 +307,12 @@ TQString KMobileProtocol::entryMimeType(int cap) } /* - * listTopDeviceDir("mobile:/<tqdevicename>") - sub-directory of a tqdevices + * listTopDeviceDir("mobile:/<devicename>") - sub-directory of a devices */ void KMobileProtocol::listTopDeviceDir(const TQString &devName) { - PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").tqarg(devName); + PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").arg(devName); KIO::UDSEntry entry; unsigned int caps = m_dev.capabilities(devName); @@ -325,7 +325,7 @@ void KMobileProtocol::listTopDeviceDir(const TQString &devName) TQString filename = m_dev.nameForCap(devName, cap); TQString mimetype = folderMimeType(cap); - createDirEntry(entry, filename, TQString("mobile:/%1/%2/").tqarg(devName).tqarg(filename), mimetype); + createDirEntry(entry, filename, TQString("mobile:/%1/%2/").arg(devName).arg(filename), mimetype); listEntry(entry, false); } listEntry(entry, true); @@ -334,13 +334,13 @@ void KMobileProtocol::listTopDeviceDir(const TQString &devName) /* - * listEntries("mobile:/<tqdevicename>/<resource>") - resources of a tqdevice + * listEntries("mobile:/<devicename>/<resource>") - resources of a device */ void KMobileProtocol::listEntries(const TQString &devName, const TQString &resource, const TQString &devPath, const KMobileDevice::Capabilities devCaps) { - PRINT_DEBUG << TQString("listEntries(%1,%2,%3)\n").tqarg(devName).tqarg(resource).tqarg(devPath); + PRINT_DEBUG << TQString("listEntries(%1,%2,%3)\n").arg(devName).arg(resource).arg(devPath); switch (devCaps) { case KMobileDevice::hasAddressBook: listAddressBook(devName, resource); break; @@ -351,16 +351,16 @@ void KMobileProtocol::listEntries(const TQString &devName, case KMobileDevice::hasFileStorage: listFileStorage(devName, resource, devPath); break; default: error( ERR_CANNOT_ENTER_DIRECTORY, - TQString("/%1/%2").tqarg(devName).tqarg(resource) ); + TQString("/%1/%2").arg(devName).arg(resource) ); } } /* - * listAddressBook("mobile:/<tqdevicename>/Addressbook) - list the addressbook + * listAddressBook("mobile:/<devicename>/Addressbook) - list the addressbook */ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listAddressBook(%1)\n").tqarg(devName); + PRINT_DEBUG << TQString("listAddressBook(%1)\n").arg(devName); KIO::UDSEntry entry; @@ -382,11 +382,11 @@ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &r name = "_" + rx.cap(1); #endif - TQString filename = TQString("%1%2.vcf").tqarg(i,fieldwidth).tqarg(name); + TQString filename = TQString("%1%2.vcf").arg(i,fieldwidth).arg(name); for (int p=0; p<fieldwidth; p++) { if (filename[p]==' ') filename[p]='0'; else break; } - TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); + TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasAddressBook), 400 /*content.utf8().length()*/ ); @@ -403,7 +403,7 @@ void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &r */ int KMobileProtocol::getVCard( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ) { - PRINT_DEBUG << TQString("getVCard(%1)\n").tqarg(path); + PRINT_DEBUG << TQString("getVCard(%1)\n").arg(path); int index = path.find('.'); if (index>0) @@ -421,11 +421,11 @@ int KMobileProtocol::getVCard( const TQString &devName, TQCString &result, TQStr } /* - * listCalendar("mobile:/<tqdevicename>/Calendar) - list the calendar entries + * listCalendar("mobile:/<devicename>/Calendar) - list the calendar entries */ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listCalendar(%1)\n").tqarg(devName); + PRINT_DEBUG << TQString("listCalendar(%1)\n").arg(devName); KIO::UDSEntry entry; @@ -433,8 +433,8 @@ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &res totalSize(entries); for (int i=0; i<entries; i++) { - TQString filename = TQString("%1_%2.vcs").tqarg(i).tqarg(i18n("calendar")); - TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); + TQString filename = TQString("%1_%2.vcs").arg(i).arg(i18n("calendar")); + TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasCalendar)); listEntry(entry, false); @@ -450,7 +450,7 @@ void KMobileProtocol::listCalendar( const TQString &devName, const TQString &res */ int KMobileProtocol::getCalendar( const TQString &devName, TQCString &result, TQString &mime, const TQString &path) { - PRINT_DEBUG << TQString("getCalendar(%1, #%2)\n").tqarg(devName).tqarg(path); + PRINT_DEBUG << TQString("getCalendar(%1, #%2)\n").arg(devName).arg(path); /* TODO */ Q_UNUSED(result); @@ -460,11 +460,11 @@ int KMobileProtocol::getCalendar( const TQString &devName, TQCString &result, TQ /* - * listNotes("mobile:/<tqdevicename>/Notes) - list the notes + * listNotes("mobile:/<devicename>/Notes) - list the notes */ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resource) { - PRINT_DEBUG << TQString("listNotes(%1)\n").tqarg(devName); + PRINT_DEBUG << TQString("listNotes(%1)\n").arg(devName); KIO::UDSEntry entry; @@ -474,8 +474,8 @@ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resour TQString note /*= m_dev.readNote(devName, i)*/; - TQString filename = TQString("%1_%2.txt").tqarg(i).tqarg(i18n("note")); - TQString url = TQString("mobile:/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(filename); + TQString filename = TQString("%1_%2.txt").arg(i).arg(i18n("note")); + TQString url = TQString("mobile:/%1/%2/%3").arg(devName).arg(resource).arg(filename); createFileEntry(entry, filename, url, entryMimeType(KMobileDevice::hasNotes), 0 /*note.utf8().length()*/); @@ -492,7 +492,7 @@ void KMobileProtocol::listNotes( const TQString &devName, const TQString &resour */ int KMobileProtocol::getNote( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ) { - PRINT_DEBUG << TQString("getNote(%1)\n").tqarg(path); + PRINT_DEBUG << TQString("getNote(%1)\n").arg(path); int index = path.find('_'); if (index>0) @@ -510,14 +510,14 @@ int KMobileProtocol::getNote( const TQString &devName, TQCString &result, TQStri } /* - * listFileStorage("mobile:/<tqdevicename>/Files) - list the files on the tqdevice + * listFileStorage("mobile:/<devicename>/Files) - list the files on the device */ void KMobileProtocol::listFileStorage(const TQString &devName, const TQString &resource, const TQString &devPath) { - PRINT_DEBUG << TQString("listFileStorage(%1,%2)\n").tqarg(devName).tqarg(devPath); + PRINT_DEBUG << TQString("listFileStorage(%1,%2)\n").arg(devName).arg(devPath); /* TODO */ - error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").tqarg(devName).tqarg(resource).tqarg(devPath) ); + error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").arg(devName).arg(resource).arg(devPath) ); } /* @@ -525,7 +525,7 @@ void KMobileProtocol::listFileStorage(const TQString &devName, const TQString &r */ int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, TQString &mime, const TQString &path) { - PRINT_DEBUG << TQString("getFileStorage(%1)\n").tqarg(path); + PRINT_DEBUG << TQString("getFileStorage(%1)\n").arg(path); /* TODO */ Q_UNUSED(devName); @@ -541,7 +541,7 @@ int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, void KMobileProtocol::stat( const KURL &url ) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("stat(%1)\n").tqarg(url.path()); + PRINT_DEBUG << TQString("stat(%1)\n").arg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -555,7 +555,7 @@ void KMobileProtocol::stat( const KURL &url ) TQStringList path = TQStringList::split('/', url.path(), false); TQString filename = (path.count()>0) ? path[path.count()-1] : "/"; TQString fullPath = path.join("/"); - TQString fullUrl = TQString("mobile:/%1").tqarg(fullPath); + TQString fullUrl = TQString("mobile:/%1").arg(fullPath); UDSEntry entry; @@ -577,7 +577,7 @@ void KMobileProtocol::stat( const KURL &url ) void KMobileProtocol::mimetype(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("mimetype(%1)\n").tqarg(url.path()); + PRINT_DEBUG << TQString("mimetype(%1)\n").arg(url.path()); KMobileDevice::Capabilities devCaps; TQString devName, resource, devPath; @@ -599,7 +599,7 @@ void KMobileProtocol::mimetype(const KURL &url) void KMobileProtocol::listDir(const KURL &url) { PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("listDir(%1)\n").tqarg(url.path()); + PRINT_DEBUG << TQString("listDir(%1)\n").arg(url.path()); if (!m_dev.isKMobileAvailable()) { error( KIO::ERR_CONNECTION_BROKEN, i18n("KDE Mobile Device Manager") ); @@ -622,7 +622,7 @@ void KMobileProtocol::listDir(const KURL &url) #if 0 if (!dev) { - error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1").tqarg(devName) ); + error( KIO::ERR_DOES_NOT_EXIST, TQString("/%1").arg(devName) ); return; } #endif diff --git a/kmobile/kioslave/mimetypes/mobile_device.desktop b/kmobile/kioslave/mimetypes/mobile_device.desktop index a04b0b8fe..4462b124d 100644 --- a/kmobile/kioslave/mimetypes/mobile_device.desktop +++ b/kmobile/kioslave/mimetypes/mobile_device.desktop @@ -58,7 +58,7 @@ Comment[zh_CN]=移动设备 Comment[zh_TW]=行動裝置 Icon=kmobile Type=MimeType -MimeType=kdetqdevice/mobiletqdevice +MimeType=kdedevice/mobiledevice Patterns= X-KDE-AutoEmbed=true |