From 64df902cf71a8ee258fb85f6be26248f399aa01f Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Sun, 27 Jan 2013 01:05:15 -0600 Subject: Rename a number of libraries and executables to avoid conflicts with KDE4 --- kmobile/DESIGN | 6 +- kmobile/Makefile.am | 2 +- kmobile/TODO | 4 +- kmobile/devices/gnokii/gnokii_mobile.cpp | 4 +- kmobile/devices/skeleton/skeleton.cpp | 2 +- kmobile/kioslave/Makefile.am | 18 - kmobile/kioslave/cellphone.protocol | 18 - kmobile/kioslave/kio_mobile.cpp | 636 --------------------- kmobile/kioslave/kio_mobile.h | 70 --- kmobile/kioslave/mimetypes/Makefile.am | 4 - .../kioslave/mimetypes/mobile_addressbook.desktop | 60 -- kmobile/kioslave/mimetypes/mobile_calendar.desktop | 60 -- kmobile/kioslave/mimetypes/mobile_device.desktop | 64 --- kmobile/kioslave/mimetypes/mobile_notes.desktop | 58 -- kmobile/kioslave/mobile.protocol | 18 - kmobile/kioslave/organizer.protocol | 18 - kmobile/kioslave/pda.protocol | 18 - kmobile/kioslave/phonecamera.protocol | 18 - kmobile/kmobile.cpp | 6 +- kmobile/kmobileclient.cpp | 4 +- kmobile/kmobiledevice.cpp | 4 +- kmobile/kmobiledevice.h | 8 +- kmobile/kmobileiface.h | 2 +- kmobile/kmobileitem.cpp | 2 +- kmobile/kmobileview.cpp | 10 +- kmobile/kmobileview.h | 2 +- kmobile/tdeioslave/Makefile.am | 18 + kmobile/tdeioslave/cellphone.protocol | 18 + kmobile/tdeioslave/kio_mobile.cpp | 636 +++++++++++++++++++++ kmobile/tdeioslave/kio_mobile.h | 70 +++ kmobile/tdeioslave/mimetypes/Makefile.am | 4 + .../mimetypes/mobile_addressbook.desktop | 60 ++ .../tdeioslave/mimetypes/mobile_calendar.desktop | 60 ++ kmobile/tdeioslave/mimetypes/mobile_device.desktop | 64 +++ kmobile/tdeioslave/mimetypes/mobile_notes.desktop | 58 ++ kmobile/tdeioslave/mobile.protocol | 18 + kmobile/tdeioslave/organizer.protocol | 18 + kmobile/tdeioslave/pda.protocol | 18 + kmobile/tdeioslave/phonecamera.protocol | 18 + 39 files changed, 1088 insertions(+), 1088 deletions(-) delete mode 100644 kmobile/kioslave/Makefile.am delete mode 100644 kmobile/kioslave/cellphone.protocol delete mode 100644 kmobile/kioslave/kio_mobile.cpp delete mode 100644 kmobile/kioslave/kio_mobile.h delete mode 100644 kmobile/kioslave/mimetypes/Makefile.am delete mode 100644 kmobile/kioslave/mimetypes/mobile_addressbook.desktop delete mode 100644 kmobile/kioslave/mimetypes/mobile_calendar.desktop delete mode 100644 kmobile/kioslave/mimetypes/mobile_device.desktop delete mode 100644 kmobile/kioslave/mimetypes/mobile_notes.desktop delete mode 100644 kmobile/kioslave/mobile.protocol delete mode 100644 kmobile/kioslave/organizer.protocol delete mode 100644 kmobile/kioslave/pda.protocol delete mode 100644 kmobile/kioslave/phonecamera.protocol create mode 100644 kmobile/tdeioslave/Makefile.am create mode 100644 kmobile/tdeioslave/cellphone.protocol create mode 100644 kmobile/tdeioslave/kio_mobile.cpp create mode 100644 kmobile/tdeioslave/kio_mobile.h create mode 100644 kmobile/tdeioslave/mimetypes/Makefile.am create mode 100644 kmobile/tdeioslave/mimetypes/mobile_addressbook.desktop create mode 100644 kmobile/tdeioslave/mimetypes/mobile_calendar.desktop create mode 100644 kmobile/tdeioslave/mimetypes/mobile_device.desktop create mode 100644 kmobile/tdeioslave/mimetypes/mobile_notes.desktop create mode 100644 kmobile/tdeioslave/mobile.protocol create mode 100644 kmobile/tdeioslave/organizer.protocol create mode 100644 kmobile/tdeioslave/pda.protocol create mode 100644 kmobile/tdeioslave/phonecamera.protocol (limited to 'kmobile') diff --git a/kmobile/DESIGN b/kmobile/DESIGN index 287a3d9a2..90ea509ec 100644 --- a/kmobile/DESIGN +++ b/kmobile/DESIGN @@ -63,7 +63,7 @@ makes accessing mobile devices completely transparent to the application. One sample program which uses the client library is the kmobile -kioslave. In Konqueror you might access any mobile device directly +tdeioslave. In Konqueror you might access any mobile device directly by giving "mobile:/" as the URL. @@ -72,8 +72,8 @@ by giving "mobile:/" as the URL. HINTS FOR DRIVER DEVELOPERS: ---------------------------- -- KMobile device drivers are very similiar to kioslaves. Refer - at the kioslave documentation if needed. +- KMobile device drivers are very similiar to tdeioslaves. Refer + at the tdeioslave documentation if needed. - derive your driver only from the KMobileDevice class (#include ) and reimplement the functions which you really need diff --git a/kmobile/Makefile.am b/kmobile/Makefile.am index 69f90bd9b..91fab1819 100644 --- a/kmobile/Makefile.am +++ b/kmobile/Makefile.am @@ -1,6 +1,6 @@ ## Makefile.am for kmobile -SUBDIRS = . devices # kioslave +SUBDIRS = . devices # tdeioslave bin_PROGRAMS = kmobile diff --git a/kmobile/TODO b/kmobile/TODO index 457393bbc..33b60b836 100644 --- a/kmobile/TODO +++ b/kmobile/TODO @@ -1,9 +1,9 @@ DONE: ----- -- devices:/ kioslave integration +- devices:/ tdeioslave integration - show per-device icons in konqueror (same as in the kmobile view) - fix mimetypes and their location under /share/mimelnk -- kioslaves: cellphone:/, organizer:/, pda:/, (camera:/ not activated) +- tdeioslaves: cellphone:/, organizer:/, pda:/, (camera:/ not activated) - system tray plugin - serial/IRDA/(USB?) locking features (acording to standards - done, but untested !!) diff --git a/kmobile/devices/gnokii/gnokii_mobile.cpp b/kmobile/devices/gnokii/gnokii_mobile.cpp index 95a014a6c..1f33996e7 100644 --- a/kmobile/devices/gnokii/gnokii_mobile.cpp +++ b/kmobile/devices/gnokii/gnokii_mobile.cpp @@ -26,10 +26,10 @@ #include #include -#include +#include #include #include -#include +#include #include #include diff --git a/kmobile/devices/skeleton/skeleton.cpp b/kmobile/devices/skeleton/skeleton.cpp index 3a7c77b07..564681cd7 100644 --- a/kmobile/devices/skeleton/skeleton.cpp +++ b/kmobile/devices/skeleton/skeleton.cpp @@ -24,7 +24,7 @@ #include #include -#include +#include #include #include diff --git a/kmobile/kioslave/Makefile.am b/kmobile/kioslave/Makefile.am deleted file mode 100644 index 6f9d24201..000000000 --- a/kmobile/kioslave/Makefile.am +++ /dev/null @@ -1,18 +0,0 @@ -SUBDIRS = mimetypes - -INCLUDES = -I$(top_srcdir)/kmobile -I$(top_srcdir) $(all_includes) - -kde_module_LTLIBRARIES = kio_mobile.la - -kio_mobile_la_SOURCES = kio_mobile.cpp -kio_mobile_la_LIBADD = $(LIB_KIO) ../libkmobileclient.la -kio_mobile_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module $(KDE_PLUGIN) - -kde_services_DATA = mobile.protocol cellphone.protocol \ - organizer.protocol pda.protocol -# do not install the camera protocol now - we already have a -# camera kioslave !! -# phonecamera.protocol - -messages: - $(XGETTEXT) *.cpp -o $(podir)/kio_mobile.pot diff --git a/kmobile/kioslave/cellphone.protocol b/kmobile/kioslave/cellphone.protocol deleted file mode 100644 index 5f37df784..000000000 --- a/kmobile/kioslave/cellphone.protocol +++ /dev/null @@ -1,18 +0,0 @@ -[Protocol] -exec=kio_mobile -protocol=cellphone -input=none -output=filesystem -# listing=Name -listing=Name,Type,URL,MimeType -reading=true -source=true -writing=true -makedir=true -deleting=true -# linking=true -# moving=true -# mimetype=text/plain -# determineMimetypeFromExtension=true -DocPath=kioslave/mobile.html -Icon=mobile_phone diff --git a/kmobile/kioslave/kio_mobile.cpp b/kmobile/kioslave/kio_mobile.cpp deleted file mode 100644 index e8cff4fa1..000000000 --- a/kmobile/kioslave/kio_mobile.cpp +++ /dev/null @@ -1,636 +0,0 @@ -/* This file is part of the KDE KMobile library - Copyright (C) 2003 Helge Deller - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License version 2 as published by the Free Software Foundation. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public License - along with this library; see the file COPYING.LIB. If not, write to - the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - Boston, MA 02110-1301, USA. - -*/ - -#include -#include - -#include -#include -#include - -#include - -#include -#include -#include -#include - -#include "kio_mobile.h" - -#include - -using namespace TDEIO; - -#define KIO_MOBILE_DEBUG_AREA 7126 -#define PRINT_DEBUG kdDebug(KIO_MOBILE_DEBUG_AREA) << "kio_mobile: " - -extern "C" { KDE_EXPORT int kdemain(int argc, char **argv); } - -/** - * The main program. - */ -int kdemain(int argc, char **argv) -{ - TDEInstance instance( "kio_mobile" ); - - PRINT_DEBUG << "Starting " << getpid() << endl; - - if (argc != 4) { - fprintf(stderr, "Usage kio_mobile protocol pool app\n"); - return -1; - } - // let the protocol class do its work - KMobileProtocol slave(argv[2], argv[3]); - - slave.dispatchLoop(); - - PRINT_DEBUG << "Done" << endl; - return 0; -} - - -/** - * Initialize the mobile slave - */ -KMobileProtocol::KMobileProtocol(const TQCString &pool, const TQCString &app) - : SlaveBase( "mobile", pool, app) -{ -} - -KMobileProtocol::~KMobileProtocol() -{ -} - -/* - * getDeviceAndRessource("mobile:///...") - split - */ -int KMobileProtocol::getDeviceAndRessource(const TQString &_path, - TQString &devName, TQString &resource, TQString &devPath, - KMobileDevice::Capabilities &devCaps) -{ -// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").arg(_path); - TQStringList path = TQStringList::split('/', _path, false); - - devName = resource = devPath = TQString(); - devCaps = KMobileDevice::hasNothing; - - if (path.count() >= 1) { devName = path[0]; path.pop_front(); }; - if (path.count() >= 1) { resource = path[0]; path.pop_front(); }; - if (path.count() >= 1) devPath = path.join("/"); - - if (devName.isEmpty()) - return 0; - - int _caps = m_dev.capabilities(devName); - - if (resource.isEmpty()) { - devCaps = (KMobileDevice::Capabilities) _caps; - return 0; - } - - for (int i=0; i<31; i++) { - int cap = 1UL << i; - if ((_caps & cap) == 0) - continue; - TQString capname = m_dev.nameForCap(devName,cap); - if (capname != resource) - continue; - devCaps = (KMobileDevice::Capabilities) cap; - return 0; - } - - return TDEIO::ERR_DOES_NOT_EXIST; -} - - -static -void addAtom(TDEIO::UDSEntry& entry, unsigned int ID, long l, const TQString& s = TQString()) -{ - TDEIO::UDSAtom atom; - atom.m_uds = ID; - atom.m_long = l; - atom.m_str = s; - entry.append(atom); -} - -static -void createDirEntry(TDEIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime) -{ - entry.clear(); - addAtom(entry, TDEIO::UDS_NAME, 0, name); - addAtom(entry, TDEIO::UDS_FILE_TYPE, S_IFDIR); - addAtom(entry, TDEIO::UDS_ACCESS, 0500); - addAtom(entry, TDEIO::UDS_MIME_TYPE, 0, mime); - addAtom(entry, TDEIO::UDS_URL, 0, url); - addAtom(entry, TDEIO::UDS_USER, 0, getenv("USER")); - addAtom(entry, TDEIO::UDS_GROUP, 0, getenv("USER")); - PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").arg(name).arg(mime).arg(url); -// addAtom(entry, TDEIO::UDS_SIZE, 0); - addAtom(entry, TDEIO::UDS_GUESSED_MIME_TYPE, 0, mime); -} - -static -void createFileEntry(TDEIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime, - const unsigned long size = 0) -{ - entry.clear(); - addAtom(entry, TDEIO::UDS_NAME, 0, name); - addAtom(entry, TDEIO::UDS_FILE_TYPE, S_IFREG); - addAtom(entry, TDEIO::UDS_URL, 0, url); - addAtom(entry, TDEIO::UDS_ACCESS, 0400); - addAtom(entry, TDEIO::UDS_USER, 0, getenv("USER")); - addAtom(entry, TDEIO::UDS_GROUP, 0, getenv("USER")); - addAtom(entry, TDEIO::UDS_MIME_TYPE, 0, mime); - if (size) addAtom(entry, TDEIO::UDS_SIZE, size); - addAtom(entry, TDEIO::UDS_GUESSED_MIME_TYPE, 0, mime); - PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").arg(name).arg(size).arg(mime); -} - - -/** - * Get the information contained in the URL. - */ -void KMobileProtocol::get(const KURL &url) -{ - PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("get(%1)\n").arg(url.path()); - - KMobileDevice::Capabilities devCaps; - TQString devName, resource, devPath; - - int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); - if (err) { - error(err, url.path()); - return; - } - - if (devName.isEmpty() || resource.isEmpty()) { - error(TDEIO::ERR_DOES_NOT_EXIST, url.path()); - return; - } - - // collect the result - TQCString result; - TQString mime; - switch (devCaps) { - case KMobileDevice::hasAddressBook: err = getVCard(devName, result, mime, devPath); - break; - case KMobileDevice::hasCalendar: err = getCalendar(devName, result, mime, devPath); - break; - case KMobileDevice::hasNotes: err = getNote(devName, result, mime, devPath); - break; - case KMobileDevice::hasFileStorage: err = getFileStorage(devName, result, mime, devPath); - break; - default: err = TDEIO::ERR_CANNOT_ENTER_DIRECTORY; /* TODO */ - } - - if (err) { - error(err, url.path()); - return; - } - - // tell the mimetype - mimeType(mime); - - // tell the length - TDEIO::filesize_t processed_size = result.length(); - totalSize(processed_size); - - // tell the contents of the URL - TQByteArray array; - array.setRawData( result.data(), result.length() ); - data(array); - array.resetRawData( result.data(), result.length() ); - processedSize( processed_size ); - // tell we are finished - data(TQByteArray()); - - // tell we are finished - finished(); -} - - -/* - * listRoot() - gives listing of all devices - */ -void KMobileProtocol::listRoot(const KURL& url) -{ - PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").arg(url.path()).arg(url.protocol()); - - TDEIO::UDSEntry entry; - - TQStringList deviceNames = m_dev.deviceNames(); - unsigned int dirs = deviceNames.count(); - totalSize(dirs); - - int classMask = KMobileDevice::Unclassified; - /* handle all possible protocols here and just add a .protocol file */ - if (url.protocol() == "cellphone") // cellphone:/ - classMask = KMobileDevice::Phone; - if (url.protocol() == "organizer" || // organizer:/ - url.protocol() == "pda") // pda:/ - classMask = KMobileDevice::Organizer; - if (url.protocol() == "phonecamera") // camera:/ - classMask = KMobileDevice::Camera; - - for (unsigned int i=0; i") - sub-directory of a devices - */ - -void KMobileProtocol::listTopDeviceDir(const TQString &devName) -{ - PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").arg(devName); - - TDEIO::UDSEntry entry; - unsigned int caps = m_dev.capabilities(devName); - - for (int i=0; i<31; i++) { - unsigned int cap = 1UL</") - 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").arg(devName).arg(resource).arg(devPath); - switch (devCaps) { - case KMobileDevice::hasAddressBook: listAddressBook(devName, resource); - break; - case KMobileDevice::hasCalendar: listCalendar(devName, resource); - break; - case KMobileDevice::hasNotes: listNotes(devName, resource); - break; - case KMobileDevice::hasFileStorage: listFileStorage(devName, resource, devPath); - break; - default: error( ERR_CANNOT_ENTER_DIRECTORY, - TQString("/%1/%2").arg(devName).arg(resource) ); - } -} - -/* - * listAddressBook("mobile://Addressbook) - list the addressbook - */ -void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &resource) -{ - PRINT_DEBUG << TQString("listAddressBook(%1)\n").arg(devName); - - TDEIO::UDSEntry entry; - - int fieldwidth; - int entries = m_dev.numAddresses(devName); - if (entries>=1000) fieldwidth=4; else - if (entries>=100) fieldwidth=3; else - if (entries>=10) fieldwidth=2; else fieldwidth=1; - totalSize(entries); -// TQRegExp rx; rx.setPattern( ".*FN:([\\w\\s]*)[\\n\\r]{2}.*" ); - TQString name; - for (int i=0; i0) - index = path.left(index).toInt(); - if (index<0 || index>=m_dev.numAddresses(devName)) - return TDEIO::ERR_DOES_NOT_EXIST; - - TQString str = m_dev.readAddress(devName, index); - if (str.isEmpty()) - return TDEIO::ERR_INTERNAL; - result = str.utf8(); - mime = entryMimeType(KMobileDevice::hasAddressBook); -// setMetaData("plugin", "const TQString &key, const TQString &value); - return 0; -} - -/* - * listCalendar("mobile://Calendar) - list the calendar entries - */ -void KMobileProtocol::listCalendar( const TQString &devName, const TQString &resource) -{ - PRINT_DEBUG << TQString("listCalendar(%1)\n").arg(devName); - - TDEIO::UDSEntry entry; - - int entries = m_dev.numCalendarEntries(devName); - totalSize(entries); - for (int i=0; i/Notes) - list the notes - */ -void KMobileProtocol::listNotes( const TQString &devName, const TQString &resource) -{ - PRINT_DEBUG << TQString("listNotes(%1)\n").arg(devName); - - TDEIO::UDSEntry entry; - - int entries = m_dev.numNotes(devName); - totalSize(entries); - for (int i=0; i0) - index = path.left(index).toInt(); - if (index<0 || index>=m_dev.numNotes(devName)) - return TDEIO::ERR_DOES_NOT_EXIST; - - TQString note = m_dev.readNote(devName, index); - if (note.isEmpty()) - return TDEIO::ERR_DOES_NOT_EXIST; - - result = note.utf8(); - mime = entryMimeType(KMobileDevice::hasNotes); - return 0; -} - -/* - * listFileStorage("mobile://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").arg(devName).arg(devPath); - - /* TODO */ - error( TDEIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").arg(devName).arg(resource).arg(devPath) ); -} - -/* - * getFileStorage() - gives the file contents of the given file - */ -int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, TQString &mime, const TQString &path) -{ - PRINT_DEBUG << TQString("getFileStorage(%1)\n").arg(path); - - /* TODO */ - Q_UNUSED(devName); - Q_UNUSED(result); - Q_UNUSED(mime); - return TDEIO::ERR_CANNOT_ENTER_DIRECTORY; -} - - -/** - * Test if the url contains a directory or a file. - */ -void KMobileProtocol::stat( const KURL &url ) -{ - PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("stat(%1)\n").arg(url.path()); - - KMobileDevice::Capabilities devCaps; - TQString devName, resource, devPath; - - int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); - if (err) { - error(err, url.path()); - return; - } - - 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").arg(fullPath); - - UDSEntry entry; - - bool isDir = devPath.isEmpty(); - - if (isDir) { - createDirEntry(entry, filename, fullUrl, folderMimeType(devCaps)); - } else { - createFileEntry(entry, filename, fullUrl, entryMimeType(devCaps)); - } - - statEntry(entry); - finished(); -} - -/** - * Get the mimetype. - */ -void KMobileProtocol::mimetype(const KURL &url) -{ - PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("mimetype(%1)\n").arg(url.path()); - - KMobileDevice::Capabilities devCaps; - TQString devName, resource, devPath; - - int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); - if (err) { - error(err, url.path()); - return; - } - - // tell the mimetype - mimeType(entryMimeType(devCaps)); - finished(); -} - -/** - * List the contents of a directory. - */ -void KMobileProtocol::listDir(const KURL &url) -{ - PRINT_DEBUG << "###############################\n"; - PRINT_DEBUG << TQString("listDir(%1)\n").arg(url.path()); - - if (!m_dev.isKMobileAvailable()) { - error( TDEIO::ERR_CONNECTION_BROKEN, i18n("TDE Mobile Device Manager") ); - return; - } - - KMobileDevice::Capabilities devCaps; - TQString devName, resource, devPath; - - int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); - if (err) { - error(err, url.path()); - return; - } - - if (devName.isEmpty()) { - listRoot(url); - return; - } - -#if 0 - if (!dev) { - error( TDEIO::ERR_DOES_NOT_EXIST, TQString("/%1").arg(devName) ); - return; - } -#endif - - if (resource.isEmpty()) { - listTopDeviceDir(devName); - return; - } - - listEntries(devName, resource, devPath, devCaps); -} diff --git a/kmobile/kioslave/kio_mobile.h b/kmobile/kioslave/kio_mobile.h deleted file mode 100644 index f534514f3..000000000 --- a/kmobile/kioslave/kio_mobile.h +++ /dev/null @@ -1,70 +0,0 @@ -/* This file is part of the KDE mobile library. - Copyright (C) 2004 Helge Deller - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Library General Public - License version 2 as published by the Free Software Foundation. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Library General Public License for more details. - - You should have received a copy of the GNU Library General Public License - along with this library; see the file COPYING.LIB. If not, write to - the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, - Boston, MA 02110-1301, USA. -*/ - -#ifndef __KIO_MOBILE_H__ -#define __KIO_MOBILE_H__ - -#include -#include - -#include -#include -#include - -class KMobileProtocol : public TDEIO::SlaveBase -{ -public: - KMobileProtocol( const TQCString &pool, const TQCString &app ); - ~KMobileProtocol(); - - void get( const KURL& url ); - void stat( const KURL& url ); - void mimetype( const KURL& url ); - void listDir( const KURL& url ); - -protected: - int getDeviceAndRessource(const TQString &_path, - TQString &devName, TQString &resource, TQString &devPath, - KMobileDevice::Capabilities &devCaps); - - TQString folderMimeType(int cap); - TQString entryMimeType(int cap); - - void listRoot(const KURL& url); - void listTopDeviceDir(const TQString &devName); - void listEntries(const TQString &devName, - const TQString &resource, const TQString &devPath, - const KMobileDevice::Capabilities devCaps); - - void listAddressBook(const TQString &devName, const TQString &resource); - int getVCard( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); - - void listCalendar(const TQString &devName, const TQString &resource); - int getCalendar( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); - - void listNotes(const TQString &devName, const TQString &resource); - int getNote( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); - - void listFileStorage(const TQString &devName, const TQString &resource, const TQString &devPath); - int getFileStorage( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); - -private: - KMobileClient m_dev; -}; - -#endif diff --git a/kmobile/kioslave/mimetypes/Makefile.am b/kmobile/kioslave/mimetypes/Makefile.am deleted file mode 100644 index 5105c51bf..000000000 --- a/kmobile/kioslave/mimetypes/Makefile.am +++ /dev/null @@ -1,4 +0,0 @@ -mimetype_DATA = \ - mobile_addressbook.desktop mobile_calendar.desktop mobile_notes.desktop \ - mobile_device.desktop -mimetypedir = $(kde_mimedir)/inode diff --git a/kmobile/kioslave/mimetypes/mobile_addressbook.desktop b/kmobile/kioslave/mimetypes/mobile_addressbook.desktop deleted file mode 100644 index cf56e0247..000000000 --- a/kmobile/kioslave/mimetypes/mobile_addressbook.desktop +++ /dev/null @@ -1,60 +0,0 @@ -[Desktop Entry] -Comment=Contacts in Mobile Device -Comment[af]=Kontakte op die draagbare toestel -Comment[ar]=المراسلون في الجهاز النقّال -Comment[be]=Кантакты ў мабільнай прыладзе -Comment[bg]=Контакти в мобилни устройства -Comment[bs]=Kontakti u mobilnom uređaju -Comment[ca]=Contactes en el dispositiu mòbil -Comment[cs]=Kontakty na mobilním zařízení -Comment[cy]=Cysylltau yn y Dyfais Symudol -Comment[da]=Kontakter i mobil-enhed -Comment[de]=Kontakte im Mobilgerät -Comment[el]=Επαφές στη φορητή συσκευή -Comment[es]=Contactos del dispositivo móvil -Comment[et]=Mobiili kontaktid -Comment[eu]=Kontaktuak dispositibo mugikorrean -Comment[fa]=تماسها در دستگاه تلفن همراه -Comment[fi]=Mobiililaitteen yhteystiedot -Comment[fr]=Contacts dans le périphérique mobile -Comment[fy]=Kontaktpersoanen yn mobyl apparaat -Comment[ga]=Teagmhálacha i nGléas Móibíleach -Comment[gl]=Contactos no dispositivo móbil -Comment[he]=אנשי קשר בהתקן הנייד -Comment[hi]=मोबाइल उपकरण में सम्पर्क -Comment[hu]=Címbejegyzések a mobiltelefonon -Comment[is]=Tengiliðir í farsíma eða lófatölvu -Comment[it]=Contatti nel dispositivo portatile -Comment[ja]=モバイル機器内の連絡先 -Comment[kk]=Қалта құрылғыдағы контакттар -Comment[km]=ទំនាក់​ទំនង​ក្នុង​ឧបករណ៍​ចល័ត -Comment[lt]=Kontaktai mobiliajame įrenginyje -Comment[mk]=Контакти од мобилен уред -Comment[ms]=Orang hubungan di dalam Peranti Mudah Alih -Comment[nb]=Kontaktliste i mobil enhet -Comment[nds]=Kontakten op de Mobilreedschap -Comment[ne]=मोबाइल यन्त्रमा सम्पर्क गर्छ -Comment[nl]=Contactpersonen in mobiel apparaat -Comment[nn]=Kontaktar i mobileiningar -Comment[pl]=Wizytówki w urządzeniu przenośnym -Comment[pt]=Contactos no Dispositivo Móvel -Comment[pt_BR]=Contatos em Dispositivo Móvel -Comment[ro]=Contacte în dispozitiv mobil -Comment[ru]=Контакты на мобильном устройстве -Comment[sk]=Kontakty v prenosnom zariadení -Comment[sl]=Stiki v prenosni napravi -Comment[sr]=Контакти у мобилном уређају -Comment[sr@Latn]=Kontakti u mobilnom uređaju -Comment[sv]=Kontakter i mobilenhet -Comment[ta]=நடமாடும் சாதனத்தின் தொடர்ப்புகள் -Comment[tg]=Алоқот дар дастгоҳи мобилӣ -Comment[tr]=Taşınabilir Aygıt Bağlantıları -Comment[uk]=Контакти у мобільному пристрої -Comment[zh_CN]=移动设备中的联系人 -Comment[zh_TW]=行動裝置中的聯絡人 -Icon=kaddressbook -Type=MimeType -MimeType=inode/addressbook -Patterns= - -X-TDE-AutoEmbed=true diff --git a/kmobile/kioslave/mimetypes/mobile_calendar.desktop b/kmobile/kioslave/mimetypes/mobile_calendar.desktop deleted file mode 100644 index 09d133ab5..000000000 --- a/kmobile/kioslave/mimetypes/mobile_calendar.desktop +++ /dev/null @@ -1,60 +0,0 @@ -[Desktop Entry] -Comment=Calendar in Mobile Device -Comment[af]=Kalender op die draagbare toestel -Comment[be]=Каляндар у мабільнай прыладзе -Comment[bg]=Календар в мобилни устройства -Comment[bs]=Kalendar u mobilnom uređaju -Comment[ca]=Calendari en el dispositiu mòbil -Comment[cs]=Kalendář na mobilním zařízení -Comment[cy]=Calendr yn y Dyfais Symudol -Comment[da]=Kalender i mobil-enhed -Comment[de]=Kalender für Mobiltelefon -Comment[el]=Ημερολόγιο στη φορητή συσκευή -Comment[eo]=Kalendaro en mobila aparato -Comment[es]=Calendario del dispositivo móvil -Comment[et]=Mobiili kalender -Comment[eu]=Egutegia dispositibo mugikorrean -Comment[fa]=تقویم در دستگاه تلفن همراه -Comment[fi]=Mobiililaitteen kalenteri -Comment[fr]=Calendrier dans un périphérique mobile -Comment[fy]=Aginda yn mobyl apparaat -Comment[ga]=Féilire i nGléas Móibíleach -Comment[gl]=Calendario no Dispositivo Móbil -Comment[he]=לוח שנה בהתקן הנייד -Comment[hi]=मोबाइल उपकरण में कैलेन्डर -Comment[hu]=Naptár a mobiltelefonon -Comment[is]=Dagatal í farsíma eða lófatölvu -Comment[it]=Calendari nel dispositivo portatile -Comment[ja]=モバイル機器内のカレンダー -Comment[kk]=Қалта құрылғыдағы күнтізбе -Comment[km]=ប្រតិទិន​ក្នុង​ឧបករណ៍​ចល័ត -Comment[lt]=Kalendorius mobiliajame įrenginyje -Comment[mk]=Календар од мобилен уред -Comment[ms]=Kalendar dalam Peranti Mudah Alih -Comment[nb]=Kalender i mobil enhet -Comment[nds]=Kalenner op Mobilreedschap -Comment[ne]=मोबाइल यन्त्रको क्यालेन्डर -Comment[nl]=Agenda in mobiel apparaat -Comment[nn]=Kalender i mobileiningar -Comment[pl]=Kalendarz w urządzeniu przenośnym -Comment[pt]=Calendário no Dispositivo Móvel -Comment[pt_BR]=Calendário em Dispositivo Móvel -Comment[ro]=Calendar în dispozitiv mobil -Comment[ru]=Календарь на мобильном устройстве -Comment[sk]=Kalendár v prenosnom zariadení -Comment[sl]=Koledar v prenosni napravi -Comment[sr]=Календар у мобилном уређају -Comment[sr@Latn]=Kalendar u mobilnom uređaju -Comment[sv]=Kalender i mobilenhet -Comment[ta]=நடமாடும் சாதனத்தில் உள்ள நாள்காட்டி -Comment[tg]=Тақвим дар дастгоҳи мобилӣ -Comment[tr]=Cep Telefonu Takvimi -Comment[uk]=Календар у мобільному пристрої -Comment[zh_CN]=移动设备中的日历 -Comment[zh_TW]=行動裝置中的行事曆 -Icon=korganizer -Type=MimeType -MimeType=inode/calendar -Patterns= - -X-TDE-AutoEmbed=true diff --git a/kmobile/kioslave/mimetypes/mobile_device.desktop b/kmobile/kioslave/mimetypes/mobile_device.desktop deleted file mode 100644 index 2f59d2dec..000000000 --- a/kmobile/kioslave/mimetypes/mobile_device.desktop +++ /dev/null @@ -1,64 +0,0 @@ -[Desktop Entry] -Comment=Mobile Device -Comment[af]=Draagbare Toestel -Comment[ar]=الجهاز النقّال -Comment[be]=Мабільная прылада -Comment[bg]=Мобилни устройства -Comment[br]=Trobarzhell lem-laka -Comment[bs]=Mobilni uređaj -Comment[ca]=Dispositiu mòbil -Comment[cs]=Mobilní zařízení -Comment[cy]=Dyfais Symudol -Comment[da]=Mobil-enhed -Comment[de]=Mobilgerät -Comment[el]=Φορητή συσκευή -Comment[eo]=Mobila aparato -Comment[es]=Dispositivo móvil -Comment[et]=Mobiil -Comment[eu]=Dispositibo mugikorra -Comment[fa]=دستگاه تلفن همراه -Comment[fi]=Mobiililaite -Comment[fr]=Périphérique mobile -Comment[fy]=Mobyl apparaat -Comment[ga]=Gléas Móibíleach -Comment[gl]=Dispositivo Móbil -Comment[he]=התקן נייד -Comment[hi]=मोबाइल उपकरण -Comment[hu]=Mobil eszköz -Comment[is]=Farsími eða lófatölva -Comment[it]=Dispositivo portatile -Comment[ja]=モバイル機器 -Comment[kk]=Қалта құрылғысы -Comment[km]=ឧបករណ៍​ចល័ត -Comment[lt]=Mobilusis įrenginys -Comment[mk]=Мобилен уред -Comment[ms]=Peranti Mudah Alih -Comment[nb]=Mobil enhet -Comment[nds]=Mobilreedschap -Comment[ne]=मोबाइल यन्त्र -Comment[nl]=Mobiel apparaat -Comment[nn]=Mobileining -Comment[pa]=ਮੋਬਾਇਲ ਜੰਤਰ -Comment[pl]=Urządzenie przenośne -Comment[pt]=Dispositivo Móvel -Comment[pt_BR]=Dispositivo Móvel -Comment[ro]=Dispozitiv mobil -Comment[ru]=Мобильное устройство -Comment[se]=Mobilovttadat -Comment[sk]=Prenosné zariadenie -Comment[sl]=Mobilna naprava -Comment[sr]=Мобилни уређај -Comment[sr@Latn]=Mobilni uređaj -Comment[sv]=Mobilenhet -Comment[ta]= நடமாடும் சாதனம் -Comment[tg]=Дастгоҳи мобилӣ -Comment[tr]=Taşınabilir Aygıt -Comment[uk]=Мобільний пристрій -Comment[zh_CN]=移动设备 -Comment[zh_TW]=行動裝置 -Icon=kmobile -Type=MimeType -MimeType=kdedevice/mobiledevice -Patterns= - -X-TDE-AutoEmbed=true diff --git a/kmobile/kioslave/mimetypes/mobile_notes.desktop b/kmobile/kioslave/mimetypes/mobile_notes.desktop deleted file mode 100644 index 7878c13d9..000000000 --- a/kmobile/kioslave/mimetypes/mobile_notes.desktop +++ /dev/null @@ -1,58 +0,0 @@ -[Desktop Entry] -Comment=Notes in Mobile Device -Comment[af]=Notas op die draagbare toestel -Comment[be]=Нататкі ў мабільнай прыладзе -Comment[bg]=Бележки в мобилни устройства -Comment[bs]=Bilješke u mobilnom uređaju -Comment[ca]=Notes en el dispositiu mòbil -Comment[cs]=Poznámky na mobilním zařízení -Comment[cy]=Nodiadau yn y Dyfais Symudol -Comment[da]=Noter i mobil-enhed -Comment[de]=Notizen im Mobilgerät -Comment[el]=Σημειώσεις στη φορητή συσκευή -Comment[es]=Notas del dispositivo móvil -Comment[et]=Mobiili märkmed (Notes) -Comment[eu]=Oharrak dispositibo mugikorrean -Comment[fa]=یادداشتها در دستگاه تلفن همراه -Comment[fi]=Mobiililaitteen muistio -Comment[fr]=Notes dans un périphérique mobile -Comment[fy]=Notysjes yn mobyl apparaat -Comment[ga]=Nótaí i nGléas Móibíleach -Comment[gl]=Notas no Dispositivo Móbil -Comment[he]=פתקים בהתקן הנייד -Comment[hi]=मोबाइल उपकरण में टीप -Comment[hu]=Feljegyzések a mobiltelefonon -Comment[is]=Áminningar í farsíma eða lófatölvu -Comment[it]=Note nel dispositivo portatile -Comment[ja]=モバイル機器内のメモ -Comment[kk]=Қалта құрылғыдағы жазбалар -Comment[km]=ចំណាំ​ក្នុង​ឧបករណ៍​ចល័ត -Comment[lt]=Užrašai mobiliajame įrenginyje -Comment[mk]=Белешки од мобилен уред -Comment[ms]=Nota dalam Peranti Mudah Alih -Comment[nb]=Notater i mobil enhet -Comment[nds]=Notizen op Mobilreedschap -Comment[ne]=मोबाइल यन्त्र भित्रका टिपोट -Comment[nl]=Notities in mobiel apparaat -Comment[nn]=Notat i mobileiningar -Comment[pl]=Notatki w urządzeniu przenośnym -Comment[pt]=Notas no Dispositivo Móvel -Comment[pt_BR]=Notas em Dispositivo Móvel -Comment[ru]=Заметки на мобильном устройстве -Comment[sk]=Poznámky v prenosnom zariadení -Comment[sl]=Notice v prenosni napravi -Comment[sr]=Белешке у мобилном уређају -Comment[sr@Latn]=Beleške u mobilnom uređaju -Comment[sv]=Anteckning i mobilenhet -Comment[ta]=நடமாடும் சாதனத்தின் குறிப்புகள் -Comment[tg]=Хабарҳо дар дастгоҳи мобилӣ -Comment[tr]=Cep Telefonu Notları -Comment[uk]=Нотатки у мобільному пристрої -Comment[zh_CN]=移动电话中的便笺 -Comment[zh_TW]=行動裝置中的備忘錄 -Icon=knotes -Type=MimeType -MimeType=inode/notes -Patterns= - -X-TDE-AutoEmbed=true diff --git a/kmobile/kioslave/mobile.protocol b/kmobile/kioslave/mobile.protocol deleted file mode 100644 index 7b8385f86..000000000 --- a/kmobile/kioslave/mobile.protocol +++ /dev/null @@ -1,18 +0,0 @@ -[Protocol] -exec=kio_mobile -protocol=mobile -input=none -output=filesystem -# listing=Name -listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType -reading=true -source=true -writing=true -makedir=true -deleting=true -# linking=true -# moving=true -# mimetype=text/plain -# determineMimetypeFromExtension=true -DocPath=kioslave/mobile.html -Icon=kaddressbook diff --git a/kmobile/kioslave/organizer.protocol b/kmobile/kioslave/organizer.protocol deleted file mode 100644 index b211a74f9..000000000 --- a/kmobile/kioslave/organizer.protocol +++ /dev/null @@ -1,18 +0,0 @@ -[Protocol] -exec=kio_mobile -protocol=organizer -input=none -output=filesystem -# listing=Name -listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType -reading=true -source=true -writing=true -makedir=true -deleting=true -# linking=true -# moving=true -# mimetype=text/plain -# determineMimetypeFromExtension=true -DocPath=kioslave/mobile.html -Icon=mobile_organizer diff --git a/kmobile/kioslave/pda.protocol b/kmobile/kioslave/pda.protocol deleted file mode 100644 index cbab2e03a..000000000 --- a/kmobile/kioslave/pda.protocol +++ /dev/null @@ -1,18 +0,0 @@ -[Protocol] -exec=kio_mobile -protocol=pda -input=none -output=filesystem -# listing=Name -listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType -reading=true -source=true -writing=true -makedir=true -deleting=true -# linking=true -# moving=true -# mimetype=text/plain -# determineMimetypeFromExtension=true -DocPath=kioslave/mobile.html -Icon=mobile_organizer diff --git a/kmobile/kioslave/phonecamera.protocol b/kmobile/kioslave/phonecamera.protocol deleted file mode 100644 index 7a0b341f2..000000000 --- a/kmobile/kioslave/phonecamera.protocol +++ /dev/null @@ -1,18 +0,0 @@ -[Protocol] -exec=kio_mobile -protocol=camera -input=none -output=filesystem -# listing=Name -listing=Name,Type,URL,MimeType -reading=true -source=true -writing=true -makedir=true -deleting=true -# linking=true -# moving=true -# mimetype=text/plain -# determineMimetypeFromExtension=true -DocPath=kioslave/mobile.html -Icon=mobile_camera diff --git a/kmobile/kmobile.cpp b/kmobile/kmobile.cpp index 2453b3bac..3e2663b5a 100644 --- a/kmobile/kmobile.cpp +++ b/kmobile/kmobile.cpp @@ -29,10 +29,10 @@ #include #include #include -#include -#include +#include +#include #include -#include +#include #include diff --git a/kmobile/kmobileclient.cpp b/kmobile/kmobileclient.cpp index 9c95efe8f..2eef7c53c 100644 --- a/kmobile/kmobileclient.cpp +++ b/kmobile/kmobileclient.cpp @@ -72,8 +72,8 @@ bool KMobileClient::startKMobileApplication() arg << TQString("kmobile") << params; TQCString replyType; TQByteArray replyData; - bool ok = call("klauncher", "klauncher", "tdeinit_exec_wait(TQString,TQStringList)", data, replyType, replyData); - PRINT_DEBUG << TQString("DCOP-CALL to klauncher: %1\n").arg(ok?"ok.":"failed."); + bool ok = call("tdelauncher", "tdelauncher", "tdeinit_exec_wait(TQString,TQStringList)", data, replyType, replyData); + PRINT_DEBUG << TQString("DCOP-CALL to tdelauncher: %1\n").arg(ok?"ok.":"failed."); return ok; } diff --git a/kmobile/kmobiledevice.cpp b/kmobile/kmobiledevice.cpp index d1e031324..3c970ab15 100644 --- a/kmobile/kmobiledevice.cpp +++ b/kmobile/kmobiledevice.cpp @@ -34,9 +34,9 @@ #include #include "kmobiledevice.h" #include -#include +#include -#include +#include #include #include diff --git a/kmobile/kmobiledevice.h b/kmobile/kmobiledevice.h index 111a26e5d..ffd568ea9 100644 --- a/kmobile/kmobiledevice.h +++ b/kmobile/kmobiledevice.h @@ -30,8 +30,8 @@ #include #include -#include -#include +#include +#include #include @@ -202,7 +202,7 @@ public: ********************** * FILE STORAGE SUPPORT ********************** - * mostly compatible to the kioslave base class + * mostly compatible to the tdeioslave base class */ /** @@ -435,7 +435,7 @@ signals: /** * Call this to show a message box from the slave (it will in fact be handled - * by kio_uiserver, so that the progress info dialog for the slave is hidden + * by tdeio_uiserver, so that the progress info dialog for the slave is hidden * while this message box is shown) * @param type type of message box: QuestionYesNo, WarningYesNo, WarningContinueCancel... * @param text Message string. May contain newlines. diff --git a/kmobile/kmobileiface.h b/kmobile/kmobileiface.h index 60974b268..bac1a9ae6 100644 --- a/kmobile/kmobileiface.h +++ b/kmobile/kmobileiface.h @@ -46,7 +46,7 @@ k_dcop: virtual bool storeNote( TQString deviceName, int index, TQString note ) = 0; /* - * DCOP functions for the devices:/ kioslave + * DCOP functions for the devices:/ tdeioslave */ k_dcop: virtual TQStringList kio_devices_deviceInfo(TQString deviceName) = 0; diff --git a/kmobile/kmobileitem.cpp b/kmobile/kmobileitem.cpp index dec9924a4..e7e97854f 100644 --- a/kmobile/kmobileitem.cpp +++ b/kmobile/kmobileitem.cpp @@ -22,7 +22,7 @@ #include #include #include -#include +#include #include "kmobileitem.h" diff --git a/kmobile/kmobileview.cpp b/kmobile/kmobileview.cpp index 0080b57a0..f90c9adf2 100644 --- a/kmobile/kmobileview.cpp +++ b/kmobile/kmobileview.cpp @@ -26,7 +26,7 @@ #include #include #include -#include +#include #include "kmobileview.h" #include "kmobileitem.h" @@ -392,17 +392,17 @@ bool KMobileView::storeNote( TQString deviceName, int index, TQString note ) /* - * DCOP Implementation for the devices:/ kioslave + * DCOP Implementation for the devices:/ tdeioslave */ /* * returns the information for the given deviceName for usage in the - * the devices kioslave. The TQStringList returned is comparable to the - * format of /etc/fstab file. Please refer to the devices kioslave for + * the devices tdeioslave. The TQStringList returned is comparable to the + * format of /etc/fstab file. Please refer to the devices tdeioslave for * further information. * If deviceName is empty, this functions returns information for all * active mobile devices. - * (function is only used by the devices kioslave - don't use elsewhere !) + * (function is only used by the devices tdeioslave - don't use elsewhere !) */ TQStringList KMobileView::kio_devices_deviceInfo(TQString deviceName) { diff --git a/kmobile/kmobileview.h b/kmobile/kmobileview.h index 39e2a53e0..4672349fd 100644 --- a/kmobile/kmobileview.h +++ b/kmobile/kmobileview.h @@ -63,7 +63,7 @@ public: TQString readNote( TQString deviceName, int index ); bool storeNote( TQString deviceName, int index, TQString note ); - /* devices kioslave support: */ + /* devices tdeioslave support: */ TQStringList kio_devices_deviceInfo(TQString deviceName); public: diff --git a/kmobile/tdeioslave/Makefile.am b/kmobile/tdeioslave/Makefile.am new file mode 100644 index 000000000..df5288ec7 --- /dev/null +++ b/kmobile/tdeioslave/Makefile.am @@ -0,0 +1,18 @@ +SUBDIRS = mimetypes + +INCLUDES = -I$(top_srcdir)/kmobile -I$(top_srcdir) $(all_includes) + +kde_module_LTLIBRARIES = kio_mobile.la + +kio_mobile_la_SOURCES = kio_mobile.cpp +kio_mobile_la_LIBADD = $(LIB_KIO) ../libkmobileclient.la +kio_mobile_la_LDFLAGS = $(all_libraries) $(KDE_RPATH) -module $(KDE_PLUGIN) + +kde_services_DATA = mobile.protocol cellphone.protocol \ + organizer.protocol pda.protocol +# do not install the camera protocol now - we already have a +# camera tdeioslave !! +# phonecamera.protocol + +messages: + $(XGETTEXT) *.cpp -o $(podir)/tdeio_mobile.pot diff --git a/kmobile/tdeioslave/cellphone.protocol b/kmobile/tdeioslave/cellphone.protocol new file mode 100644 index 000000000..c47e25472 --- /dev/null +++ b/kmobile/tdeioslave/cellphone.protocol @@ -0,0 +1,18 @@ +[Protocol] +exec=kio_mobile +protocol=cellphone +input=none +output=filesystem +# listing=Name +listing=Name,Type,URL,MimeType +reading=true +source=true +writing=true +makedir=true +deleting=true +# linking=true +# moving=true +# mimetype=text/plain +# determineMimetypeFromExtension=true +DocPath=tdeioslave/mobile.html +Icon=mobile_phone diff --git a/kmobile/tdeioslave/kio_mobile.cpp b/kmobile/tdeioslave/kio_mobile.cpp new file mode 100644 index 000000000..e8cff4fa1 --- /dev/null +++ b/kmobile/tdeioslave/kio_mobile.cpp @@ -0,0 +1,636 @@ +/* This file is part of the KDE KMobile library + Copyright (C) 2003 Helge Deller + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License version 2 as published by the Free Software Foundation. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public License + along with this library; see the file COPYING.LIB. If not, write to + the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. + +*/ + +#include +#include + +#include +#include +#include + +#include + +#include +#include +#include +#include + +#include "kio_mobile.h" + +#include + +using namespace TDEIO; + +#define KIO_MOBILE_DEBUG_AREA 7126 +#define PRINT_DEBUG kdDebug(KIO_MOBILE_DEBUG_AREA) << "kio_mobile: " + +extern "C" { KDE_EXPORT int kdemain(int argc, char **argv); } + +/** + * The main program. + */ +int kdemain(int argc, char **argv) +{ + TDEInstance instance( "kio_mobile" ); + + PRINT_DEBUG << "Starting " << getpid() << endl; + + if (argc != 4) { + fprintf(stderr, "Usage kio_mobile protocol pool app\n"); + return -1; + } + // let the protocol class do its work + KMobileProtocol slave(argv[2], argv[3]); + + slave.dispatchLoop(); + + PRINT_DEBUG << "Done" << endl; + return 0; +} + + +/** + * Initialize the mobile slave + */ +KMobileProtocol::KMobileProtocol(const TQCString &pool, const TQCString &app) + : SlaveBase( "mobile", pool, app) +{ +} + +KMobileProtocol::~KMobileProtocol() +{ +} + +/* + * getDeviceAndRessource("mobile:///...") - split + */ +int KMobileProtocol::getDeviceAndRessource(const TQString &_path, + TQString &devName, TQString &resource, TQString &devPath, + KMobileDevice::Capabilities &devCaps) +{ +// PRINT_DEBUG << TQString("###getDeviceAndRessource### %1\n").arg(_path); + TQStringList path = TQStringList::split('/', _path, false); + + devName = resource = devPath = TQString(); + devCaps = KMobileDevice::hasNothing; + + if (path.count() >= 1) { devName = path[0]; path.pop_front(); }; + if (path.count() >= 1) { resource = path[0]; path.pop_front(); }; + if (path.count() >= 1) devPath = path.join("/"); + + if (devName.isEmpty()) + return 0; + + int _caps = m_dev.capabilities(devName); + + if (resource.isEmpty()) { + devCaps = (KMobileDevice::Capabilities) _caps; + return 0; + } + + for (int i=0; i<31; i++) { + int cap = 1UL << i; + if ((_caps & cap) == 0) + continue; + TQString capname = m_dev.nameForCap(devName,cap); + if (capname != resource) + continue; + devCaps = (KMobileDevice::Capabilities) cap; + return 0; + } + + return TDEIO::ERR_DOES_NOT_EXIST; +} + + +static +void addAtom(TDEIO::UDSEntry& entry, unsigned int ID, long l, const TQString& s = TQString()) +{ + TDEIO::UDSAtom atom; + atom.m_uds = ID; + atom.m_long = l; + atom.m_str = s; + entry.append(atom); +} + +static +void createDirEntry(TDEIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime) +{ + entry.clear(); + addAtom(entry, TDEIO::UDS_NAME, 0, name); + addAtom(entry, TDEIO::UDS_FILE_TYPE, S_IFDIR); + addAtom(entry, TDEIO::UDS_ACCESS, 0500); + addAtom(entry, TDEIO::UDS_MIME_TYPE, 0, mime); + addAtom(entry, TDEIO::UDS_URL, 0, url); + addAtom(entry, TDEIO::UDS_USER, 0, getenv("USER")); + addAtom(entry, TDEIO::UDS_GROUP, 0, getenv("USER")); + PRINT_DEBUG << TQString("createDirEntry: File: %1 MIME: %2 URL: %3\n").arg(name).arg(mime).arg(url); +// addAtom(entry, TDEIO::UDS_SIZE, 0); + addAtom(entry, TDEIO::UDS_GUESSED_MIME_TYPE, 0, mime); +} + +static +void createFileEntry(TDEIO::UDSEntry& entry, const TQString& name, const TQString& url, const TQString& mime, + const unsigned long size = 0) +{ + entry.clear(); + addAtom(entry, TDEIO::UDS_NAME, 0, name); + addAtom(entry, TDEIO::UDS_FILE_TYPE, S_IFREG); + addAtom(entry, TDEIO::UDS_URL, 0, url); + addAtom(entry, TDEIO::UDS_ACCESS, 0400); + addAtom(entry, TDEIO::UDS_USER, 0, getenv("USER")); + addAtom(entry, TDEIO::UDS_GROUP, 0, getenv("USER")); + addAtom(entry, TDEIO::UDS_MIME_TYPE, 0, mime); + if (size) addAtom(entry, TDEIO::UDS_SIZE, size); + addAtom(entry, TDEIO::UDS_GUESSED_MIME_TYPE, 0, mime); + PRINT_DEBUG << TQString("createFileEntry: File: %1, Size: %2, MIME: %3\n").arg(name).arg(size).arg(mime); +} + + +/** + * Get the information contained in the URL. + */ +void KMobileProtocol::get(const KURL &url) +{ + PRINT_DEBUG << "###############################\n"; + PRINT_DEBUG << TQString("get(%1)\n").arg(url.path()); + + KMobileDevice::Capabilities devCaps; + TQString devName, resource, devPath; + + int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); + if (err) { + error(err, url.path()); + return; + } + + if (devName.isEmpty() || resource.isEmpty()) { + error(TDEIO::ERR_DOES_NOT_EXIST, url.path()); + return; + } + + // collect the result + TQCString result; + TQString mime; + switch (devCaps) { + case KMobileDevice::hasAddressBook: err = getVCard(devName, result, mime, devPath); + break; + case KMobileDevice::hasCalendar: err = getCalendar(devName, result, mime, devPath); + break; + case KMobileDevice::hasNotes: err = getNote(devName, result, mime, devPath); + break; + case KMobileDevice::hasFileStorage: err = getFileStorage(devName, result, mime, devPath); + break; + default: err = TDEIO::ERR_CANNOT_ENTER_DIRECTORY; /* TODO */ + } + + if (err) { + error(err, url.path()); + return; + } + + // tell the mimetype + mimeType(mime); + + // tell the length + TDEIO::filesize_t processed_size = result.length(); + totalSize(processed_size); + + // tell the contents of the URL + TQByteArray array; + array.setRawData( result.data(), result.length() ); + data(array); + array.resetRawData( result.data(), result.length() ); + processedSize( processed_size ); + // tell we are finished + data(TQByteArray()); + + // tell we are finished + finished(); +} + + +/* + * listRoot() - gives listing of all devices + */ +void KMobileProtocol::listRoot(const KURL& url) +{ + PRINT_DEBUG << TQString("########## listRoot(%1) for %2:/\n").arg(url.path()).arg(url.protocol()); + + TDEIO::UDSEntry entry; + + TQStringList deviceNames = m_dev.deviceNames(); + unsigned int dirs = deviceNames.count(); + totalSize(dirs); + + int classMask = KMobileDevice::Unclassified; + /* handle all possible protocols here and just add a .protocol file */ + if (url.protocol() == "cellphone") // cellphone:/ + classMask = KMobileDevice::Phone; + if (url.protocol() == "organizer" || // organizer:/ + url.protocol() == "pda") // pda:/ + classMask = KMobileDevice::Organizer; + if (url.protocol() == "phonecamera") // camera:/ + classMask = KMobileDevice::Camera; + + for (unsigned int i=0; i") - sub-directory of a devices + */ + +void KMobileProtocol::listTopDeviceDir(const TQString &devName) +{ + PRINT_DEBUG << TQString("listTopDeviceDir(%1)\n").arg(devName); + + TDEIO::UDSEntry entry; + unsigned int caps = m_dev.capabilities(devName); + + for (int i=0; i<31; i++) { + unsigned int cap = 1UL</") - 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").arg(devName).arg(resource).arg(devPath); + switch (devCaps) { + case KMobileDevice::hasAddressBook: listAddressBook(devName, resource); + break; + case KMobileDevice::hasCalendar: listCalendar(devName, resource); + break; + case KMobileDevice::hasNotes: listNotes(devName, resource); + break; + case KMobileDevice::hasFileStorage: listFileStorage(devName, resource, devPath); + break; + default: error( ERR_CANNOT_ENTER_DIRECTORY, + TQString("/%1/%2").arg(devName).arg(resource) ); + } +} + +/* + * listAddressBook("mobile://Addressbook) - list the addressbook + */ +void KMobileProtocol::listAddressBook(const TQString &devName, const TQString &resource) +{ + PRINT_DEBUG << TQString("listAddressBook(%1)\n").arg(devName); + + TDEIO::UDSEntry entry; + + int fieldwidth; + int entries = m_dev.numAddresses(devName); + if (entries>=1000) fieldwidth=4; else + if (entries>=100) fieldwidth=3; else + if (entries>=10) fieldwidth=2; else fieldwidth=1; + totalSize(entries); +// TQRegExp rx; rx.setPattern( ".*FN:([\\w\\s]*)[\\n\\r]{2}.*" ); + TQString name; + for (int i=0; i0) + index = path.left(index).toInt(); + if (index<0 || index>=m_dev.numAddresses(devName)) + return TDEIO::ERR_DOES_NOT_EXIST; + + TQString str = m_dev.readAddress(devName, index); + if (str.isEmpty()) + return TDEIO::ERR_INTERNAL; + result = str.utf8(); + mime = entryMimeType(KMobileDevice::hasAddressBook); +// setMetaData("plugin", "const TQString &key, const TQString &value); + return 0; +} + +/* + * listCalendar("mobile://Calendar) - list the calendar entries + */ +void KMobileProtocol::listCalendar( const TQString &devName, const TQString &resource) +{ + PRINT_DEBUG << TQString("listCalendar(%1)\n").arg(devName); + + TDEIO::UDSEntry entry; + + int entries = m_dev.numCalendarEntries(devName); + totalSize(entries); + for (int i=0; i/Notes) - list the notes + */ +void KMobileProtocol::listNotes( const TQString &devName, const TQString &resource) +{ + PRINT_DEBUG << TQString("listNotes(%1)\n").arg(devName); + + TDEIO::UDSEntry entry; + + int entries = m_dev.numNotes(devName); + totalSize(entries); + for (int i=0; i0) + index = path.left(index).toInt(); + if (index<0 || index>=m_dev.numNotes(devName)) + return TDEIO::ERR_DOES_NOT_EXIST; + + TQString note = m_dev.readNote(devName, index); + if (note.isEmpty()) + return TDEIO::ERR_DOES_NOT_EXIST; + + result = note.utf8(); + mime = entryMimeType(KMobileDevice::hasNotes); + return 0; +} + +/* + * listFileStorage("mobile://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").arg(devName).arg(devPath); + + /* TODO */ + error( TDEIO::ERR_DOES_NOT_EXIST, TQString("/%1/%2/%3").arg(devName).arg(resource).arg(devPath) ); +} + +/* + * getFileStorage() - gives the file contents of the given file + */ +int KMobileProtocol::getFileStorage(const TQString &devName, TQCString &result, TQString &mime, const TQString &path) +{ + PRINT_DEBUG << TQString("getFileStorage(%1)\n").arg(path); + + /* TODO */ + Q_UNUSED(devName); + Q_UNUSED(result); + Q_UNUSED(mime); + return TDEIO::ERR_CANNOT_ENTER_DIRECTORY; +} + + +/** + * Test if the url contains a directory or a file. + */ +void KMobileProtocol::stat( const KURL &url ) +{ + PRINT_DEBUG << "###############################\n"; + PRINT_DEBUG << TQString("stat(%1)\n").arg(url.path()); + + KMobileDevice::Capabilities devCaps; + TQString devName, resource, devPath; + + int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); + if (err) { + error(err, url.path()); + return; + } + + 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").arg(fullPath); + + UDSEntry entry; + + bool isDir = devPath.isEmpty(); + + if (isDir) { + createDirEntry(entry, filename, fullUrl, folderMimeType(devCaps)); + } else { + createFileEntry(entry, filename, fullUrl, entryMimeType(devCaps)); + } + + statEntry(entry); + finished(); +} + +/** + * Get the mimetype. + */ +void KMobileProtocol::mimetype(const KURL &url) +{ + PRINT_DEBUG << "###############################\n"; + PRINT_DEBUG << TQString("mimetype(%1)\n").arg(url.path()); + + KMobileDevice::Capabilities devCaps; + TQString devName, resource, devPath; + + int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); + if (err) { + error(err, url.path()); + return; + } + + // tell the mimetype + mimeType(entryMimeType(devCaps)); + finished(); +} + +/** + * List the contents of a directory. + */ +void KMobileProtocol::listDir(const KURL &url) +{ + PRINT_DEBUG << "###############################\n"; + PRINT_DEBUG << TQString("listDir(%1)\n").arg(url.path()); + + if (!m_dev.isKMobileAvailable()) { + error( TDEIO::ERR_CONNECTION_BROKEN, i18n("TDE Mobile Device Manager") ); + return; + } + + KMobileDevice::Capabilities devCaps; + TQString devName, resource, devPath; + + int err = getDeviceAndRessource(url.path(), devName, resource, devPath, devCaps); + if (err) { + error(err, url.path()); + return; + } + + if (devName.isEmpty()) { + listRoot(url); + return; + } + +#if 0 + if (!dev) { + error( TDEIO::ERR_DOES_NOT_EXIST, TQString("/%1").arg(devName) ); + return; + } +#endif + + if (resource.isEmpty()) { + listTopDeviceDir(devName); + return; + } + + listEntries(devName, resource, devPath, devCaps); +} diff --git a/kmobile/tdeioslave/kio_mobile.h b/kmobile/tdeioslave/kio_mobile.h new file mode 100644 index 000000000..05a30a22f --- /dev/null +++ b/kmobile/tdeioslave/kio_mobile.h @@ -0,0 +1,70 @@ +/* This file is part of the KDE mobile library. + Copyright (C) 2004 Helge Deller + + This library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public + License version 2 as published by the Free Software Foundation. + + This library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public License + along with this library; see the file COPYING.LIB. If not, write to + the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. +*/ + +#ifndef __KIO_MOBILE_H__ +#define __KIO_MOBILE_H__ + +#include +#include + +#include +#include +#include + +class KMobileProtocol : public TDEIO::SlaveBase +{ +public: + KMobileProtocol( const TQCString &pool, const TQCString &app ); + ~KMobileProtocol(); + + void get( const KURL& url ); + void stat( const KURL& url ); + void mimetype( const KURL& url ); + void listDir( const KURL& url ); + +protected: + int getDeviceAndRessource(const TQString &_path, + TQString &devName, TQString &resource, TQString &devPath, + KMobileDevice::Capabilities &devCaps); + + TQString folderMimeType(int cap); + TQString entryMimeType(int cap); + + void listRoot(const KURL& url); + void listTopDeviceDir(const TQString &devName); + void listEntries(const TQString &devName, + const TQString &resource, const TQString &devPath, + const KMobileDevice::Capabilities devCaps); + + void listAddressBook(const TQString &devName, const TQString &resource); + int getVCard( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); + + void listCalendar(const TQString &devName, const TQString &resource); + int getCalendar( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); + + void listNotes(const TQString &devName, const TQString &resource); + int getNote( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); + + void listFileStorage(const TQString &devName, const TQString &resource, const TQString &devPath); + int getFileStorage( const TQString &devName, TQCString &result, TQString &mime, const TQString &path ); + +private: + KMobileClient m_dev; +}; + +#endif diff --git a/kmobile/tdeioslave/mimetypes/Makefile.am b/kmobile/tdeioslave/mimetypes/Makefile.am new file mode 100644 index 000000000..5105c51bf --- /dev/null +++ b/kmobile/tdeioslave/mimetypes/Makefile.am @@ -0,0 +1,4 @@ +mimetype_DATA = \ + mobile_addressbook.desktop mobile_calendar.desktop mobile_notes.desktop \ + mobile_device.desktop +mimetypedir = $(kde_mimedir)/inode diff --git a/kmobile/tdeioslave/mimetypes/mobile_addressbook.desktop b/kmobile/tdeioslave/mimetypes/mobile_addressbook.desktop new file mode 100644 index 000000000..cf56e0247 --- /dev/null +++ b/kmobile/tdeioslave/mimetypes/mobile_addressbook.desktop @@ -0,0 +1,60 @@ +[Desktop Entry] +Comment=Contacts in Mobile Device +Comment[af]=Kontakte op die draagbare toestel +Comment[ar]=المراسلون في الجهاز النقّال +Comment[be]=Кантакты ў мабільнай прыладзе +Comment[bg]=Контакти в мобилни устройства +Comment[bs]=Kontakti u mobilnom uređaju +Comment[ca]=Contactes en el dispositiu mòbil +Comment[cs]=Kontakty na mobilním zařízení +Comment[cy]=Cysylltau yn y Dyfais Symudol +Comment[da]=Kontakter i mobil-enhed +Comment[de]=Kontakte im Mobilgerät +Comment[el]=Επαφές στη φορητή συσκευή +Comment[es]=Contactos del dispositivo móvil +Comment[et]=Mobiili kontaktid +Comment[eu]=Kontaktuak dispositibo mugikorrean +Comment[fa]=تماسها در دستگاه تلفن همراه +Comment[fi]=Mobiililaitteen yhteystiedot +Comment[fr]=Contacts dans le périphérique mobile +Comment[fy]=Kontaktpersoanen yn mobyl apparaat +Comment[ga]=Teagmhálacha i nGléas Móibíleach +Comment[gl]=Contactos no dispositivo móbil +Comment[he]=אנשי קשר בהתקן הנייד +Comment[hi]=मोबाइल उपकरण में सम्पर्क +Comment[hu]=Címbejegyzések a mobiltelefonon +Comment[is]=Tengiliðir í farsíma eða lófatölvu +Comment[it]=Contatti nel dispositivo portatile +Comment[ja]=モバイル機器内の連絡先 +Comment[kk]=Қалта құрылғыдағы контакттар +Comment[km]=ទំនាក់​ទំនង​ក្នុង​ឧបករណ៍​ចល័ត +Comment[lt]=Kontaktai mobiliajame įrenginyje +Comment[mk]=Контакти од мобилен уред +Comment[ms]=Orang hubungan di dalam Peranti Mudah Alih +Comment[nb]=Kontaktliste i mobil enhet +Comment[nds]=Kontakten op de Mobilreedschap +Comment[ne]=मोबाइल यन्त्रमा सम्पर्क गर्छ +Comment[nl]=Contactpersonen in mobiel apparaat +Comment[nn]=Kontaktar i mobileiningar +Comment[pl]=Wizytówki w urządzeniu przenośnym +Comment[pt]=Contactos no Dispositivo Móvel +Comment[pt_BR]=Contatos em Dispositivo Móvel +Comment[ro]=Contacte în dispozitiv mobil +Comment[ru]=Контакты на мобильном устройстве +Comment[sk]=Kontakty v prenosnom zariadení +Comment[sl]=Stiki v prenosni napravi +Comment[sr]=Контакти у мобилном уређају +Comment[sr@Latn]=Kontakti u mobilnom uređaju +Comment[sv]=Kontakter i mobilenhet +Comment[ta]=நடமாடும் சாதனத்தின் தொடர்ப்புகள் +Comment[tg]=Алоқот дар дастгоҳи мобилӣ +Comment[tr]=Taşınabilir Aygıt Bağlantıları +Comment[uk]=Контакти у мобільному пристрої +Comment[zh_CN]=移动设备中的联系人 +Comment[zh_TW]=行動裝置中的聯絡人 +Icon=kaddressbook +Type=MimeType +MimeType=inode/addressbook +Patterns= + +X-TDE-AutoEmbed=true diff --git a/kmobile/tdeioslave/mimetypes/mobile_calendar.desktop b/kmobile/tdeioslave/mimetypes/mobile_calendar.desktop new file mode 100644 index 000000000..09d133ab5 --- /dev/null +++ b/kmobile/tdeioslave/mimetypes/mobile_calendar.desktop @@ -0,0 +1,60 @@ +[Desktop Entry] +Comment=Calendar in Mobile Device +Comment[af]=Kalender op die draagbare toestel +Comment[be]=Каляндар у мабільнай прыладзе +Comment[bg]=Календар в мобилни устройства +Comment[bs]=Kalendar u mobilnom uređaju +Comment[ca]=Calendari en el dispositiu mòbil +Comment[cs]=Kalendář na mobilním zařízení +Comment[cy]=Calendr yn y Dyfais Symudol +Comment[da]=Kalender i mobil-enhed +Comment[de]=Kalender für Mobiltelefon +Comment[el]=Ημερολόγιο στη φορητή συσκευή +Comment[eo]=Kalendaro en mobila aparato +Comment[es]=Calendario del dispositivo móvil +Comment[et]=Mobiili kalender +Comment[eu]=Egutegia dispositibo mugikorrean +Comment[fa]=تقویم در دستگاه تلفن همراه +Comment[fi]=Mobiililaitteen kalenteri +Comment[fr]=Calendrier dans un périphérique mobile +Comment[fy]=Aginda yn mobyl apparaat +Comment[ga]=Féilire i nGléas Móibíleach +Comment[gl]=Calendario no Dispositivo Móbil +Comment[he]=לוח שנה בהתקן הנייד +Comment[hi]=मोबाइल उपकरण में कैलेन्डर +Comment[hu]=Naptár a mobiltelefonon +Comment[is]=Dagatal í farsíma eða lófatölvu +Comment[it]=Calendari nel dispositivo portatile +Comment[ja]=モバイル機器内のカレンダー +Comment[kk]=Қалта құрылғыдағы күнтізбе +Comment[km]=ប្រតិទិន​ក្នុង​ឧបករណ៍​ចល័ត +Comment[lt]=Kalendorius mobiliajame įrenginyje +Comment[mk]=Календар од мобилен уред +Comment[ms]=Kalendar dalam Peranti Mudah Alih +Comment[nb]=Kalender i mobil enhet +Comment[nds]=Kalenner op Mobilreedschap +Comment[ne]=मोबाइल यन्त्रको क्यालेन्डर +Comment[nl]=Agenda in mobiel apparaat +Comment[nn]=Kalender i mobileiningar +Comment[pl]=Kalendarz w urządzeniu przenośnym +Comment[pt]=Calendário no Dispositivo Móvel +Comment[pt_BR]=Calendário em Dispositivo Móvel +Comment[ro]=Calendar în dispozitiv mobil +Comment[ru]=Календарь на мобильном устройстве +Comment[sk]=Kalendár v prenosnom zariadení +Comment[sl]=Koledar v prenosni napravi +Comment[sr]=Календар у мобилном уређају +Comment[sr@Latn]=Kalendar u mobilnom uređaju +Comment[sv]=Kalender i mobilenhet +Comment[ta]=நடமாடும் சாதனத்தில் உள்ள நாள்காட்டி +Comment[tg]=Тақвим дар дастгоҳи мобилӣ +Comment[tr]=Cep Telefonu Takvimi +Comment[uk]=Календар у мобільному пристрої +Comment[zh_CN]=移动设备中的日历 +Comment[zh_TW]=行動裝置中的行事曆 +Icon=korganizer +Type=MimeType +MimeType=inode/calendar +Patterns= + +X-TDE-AutoEmbed=true diff --git a/kmobile/tdeioslave/mimetypes/mobile_device.desktop b/kmobile/tdeioslave/mimetypes/mobile_device.desktop new file mode 100644 index 000000000..2f59d2dec --- /dev/null +++ b/kmobile/tdeioslave/mimetypes/mobile_device.desktop @@ -0,0 +1,64 @@ +[Desktop Entry] +Comment=Mobile Device +Comment[af]=Draagbare Toestel +Comment[ar]=الجهاز النقّال +Comment[be]=Мабільная прылада +Comment[bg]=Мобилни устройства +Comment[br]=Trobarzhell lem-laka +Comment[bs]=Mobilni uređaj +Comment[ca]=Dispositiu mòbil +Comment[cs]=Mobilní zařízení +Comment[cy]=Dyfais Symudol +Comment[da]=Mobil-enhed +Comment[de]=Mobilgerät +Comment[el]=Φορητή συσκευή +Comment[eo]=Mobila aparato +Comment[es]=Dispositivo móvil +Comment[et]=Mobiil +Comment[eu]=Dispositibo mugikorra +Comment[fa]=دستگاه تلفن همراه +Comment[fi]=Mobiililaite +Comment[fr]=Périphérique mobile +Comment[fy]=Mobyl apparaat +Comment[ga]=Gléas Móibíleach +Comment[gl]=Dispositivo Móbil +Comment[he]=התקן נייד +Comment[hi]=मोबाइल उपकरण +Comment[hu]=Mobil eszköz +Comment[is]=Farsími eða lófatölva +Comment[it]=Dispositivo portatile +Comment[ja]=モバイル機器 +Comment[kk]=Қалта құрылғысы +Comment[km]=ឧបករណ៍​ចល័ត +Comment[lt]=Mobilusis įrenginys +Comment[mk]=Мобилен уред +Comment[ms]=Peranti Mudah Alih +Comment[nb]=Mobil enhet +Comment[nds]=Mobilreedschap +Comment[ne]=मोबाइल यन्त्र +Comment[nl]=Mobiel apparaat +Comment[nn]=Mobileining +Comment[pa]=ਮੋਬਾਇਲ ਜੰਤਰ +Comment[pl]=Urządzenie przenośne +Comment[pt]=Dispositivo Móvel +Comment[pt_BR]=Dispositivo Móvel +Comment[ro]=Dispozitiv mobil +Comment[ru]=Мобильное устройство +Comment[se]=Mobilovttadat +Comment[sk]=Prenosné zariadenie +Comment[sl]=Mobilna naprava +Comment[sr]=Мобилни уређај +Comment[sr@Latn]=Mobilni uređaj +Comment[sv]=Mobilenhet +Comment[ta]= நடமாடும் சாதனம் +Comment[tg]=Дастгоҳи мобилӣ +Comment[tr]=Taşınabilir Aygıt +Comment[uk]=Мобільний пристрій +Comment[zh_CN]=移动设备 +Comment[zh_TW]=行動裝置 +Icon=kmobile +Type=MimeType +MimeType=kdedevice/mobiledevice +Patterns= + +X-TDE-AutoEmbed=true diff --git a/kmobile/tdeioslave/mimetypes/mobile_notes.desktop b/kmobile/tdeioslave/mimetypes/mobile_notes.desktop new file mode 100644 index 000000000..7878c13d9 --- /dev/null +++ b/kmobile/tdeioslave/mimetypes/mobile_notes.desktop @@ -0,0 +1,58 @@ +[Desktop Entry] +Comment=Notes in Mobile Device +Comment[af]=Notas op die draagbare toestel +Comment[be]=Нататкі ў мабільнай прыладзе +Comment[bg]=Бележки в мобилни устройства +Comment[bs]=Bilješke u mobilnom uređaju +Comment[ca]=Notes en el dispositiu mòbil +Comment[cs]=Poznámky na mobilním zařízení +Comment[cy]=Nodiadau yn y Dyfais Symudol +Comment[da]=Noter i mobil-enhed +Comment[de]=Notizen im Mobilgerät +Comment[el]=Σημειώσεις στη φορητή συσκευή +Comment[es]=Notas del dispositivo móvil +Comment[et]=Mobiili märkmed (Notes) +Comment[eu]=Oharrak dispositibo mugikorrean +Comment[fa]=یادداشتها در دستگاه تلفن همراه +Comment[fi]=Mobiililaitteen muistio +Comment[fr]=Notes dans un périphérique mobile +Comment[fy]=Notysjes yn mobyl apparaat +Comment[ga]=Nótaí i nGléas Móibíleach +Comment[gl]=Notas no Dispositivo Móbil +Comment[he]=פתקים בהתקן הנייד +Comment[hi]=मोबाइल उपकरण में टीप +Comment[hu]=Feljegyzések a mobiltelefonon +Comment[is]=Áminningar í farsíma eða lófatölvu +Comment[it]=Note nel dispositivo portatile +Comment[ja]=モバイル機器内のメモ +Comment[kk]=Қалта құрылғыдағы жазбалар +Comment[km]=ចំណាំ​ក្នុង​ឧបករណ៍​ចល័ត +Comment[lt]=Užrašai mobiliajame įrenginyje +Comment[mk]=Белешки од мобилен уред +Comment[ms]=Nota dalam Peranti Mudah Alih +Comment[nb]=Notater i mobil enhet +Comment[nds]=Notizen op Mobilreedschap +Comment[ne]=मोबाइल यन्त्र भित्रका टिपोट +Comment[nl]=Notities in mobiel apparaat +Comment[nn]=Notat i mobileiningar +Comment[pl]=Notatki w urządzeniu przenośnym +Comment[pt]=Notas no Dispositivo Móvel +Comment[pt_BR]=Notas em Dispositivo Móvel +Comment[ru]=Заметки на мобильном устройстве +Comment[sk]=Poznámky v prenosnom zariadení +Comment[sl]=Notice v prenosni napravi +Comment[sr]=Белешке у мобилном уређају +Comment[sr@Latn]=Beleške u mobilnom uređaju +Comment[sv]=Anteckning i mobilenhet +Comment[ta]=நடமாடும் சாதனத்தின் குறிப்புகள் +Comment[tg]=Хабарҳо дар дастгоҳи мобилӣ +Comment[tr]=Cep Telefonu Notları +Comment[uk]=Нотатки у мобільному пристрої +Comment[zh_CN]=移动电话中的便笺 +Comment[zh_TW]=行動裝置中的備忘錄 +Icon=knotes +Type=MimeType +MimeType=inode/notes +Patterns= + +X-TDE-AutoEmbed=true diff --git a/kmobile/tdeioslave/mobile.protocol b/kmobile/tdeioslave/mobile.protocol new file mode 100644 index 000000000..e87d7154b --- /dev/null +++ b/kmobile/tdeioslave/mobile.protocol @@ -0,0 +1,18 @@ +[Protocol] +exec=kio_mobile +protocol=mobile +input=none +output=filesystem +# listing=Name +listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType +reading=true +source=true +writing=true +makedir=true +deleting=true +# linking=true +# moving=true +# mimetype=text/plain +# determineMimetypeFromExtension=true +DocPath=tdeioslave/mobile.html +Icon=kaddressbook diff --git a/kmobile/tdeioslave/organizer.protocol b/kmobile/tdeioslave/organizer.protocol new file mode 100644 index 000000000..3b83e002f --- /dev/null +++ b/kmobile/tdeioslave/organizer.protocol @@ -0,0 +1,18 @@ +[Protocol] +exec=kio_mobile +protocol=organizer +input=none +output=filesystem +# listing=Name +listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType +reading=true +source=true +writing=true +makedir=true +deleting=true +# linking=true +# moving=true +# mimetype=text/plain +# determineMimetypeFromExtension=true +DocPath=tdeioslave/mobile.html +Icon=mobile_organizer diff --git a/kmobile/tdeioslave/pda.protocol b/kmobile/tdeioslave/pda.protocol new file mode 100644 index 000000000..8113b5bfa --- /dev/null +++ b/kmobile/tdeioslave/pda.protocol @@ -0,0 +1,18 @@ +[Protocol] +exec=kio_mobile +protocol=pda +input=none +output=filesystem +# listing=Name +listing=Name,Type,Size,Date,AccessDate,Access,URL,MimeType +reading=true +source=true +writing=true +makedir=true +deleting=true +# linking=true +# moving=true +# mimetype=text/plain +# determineMimetypeFromExtension=true +DocPath=tdeioslave/mobile.html +Icon=mobile_organizer diff --git a/kmobile/tdeioslave/phonecamera.protocol b/kmobile/tdeioslave/phonecamera.protocol new file mode 100644 index 000000000..296ebccb5 --- /dev/null +++ b/kmobile/tdeioslave/phonecamera.protocol @@ -0,0 +1,18 @@ +[Protocol] +exec=kio_mobile +protocol=camera +input=none +output=filesystem +# listing=Name +listing=Name,Type,URL,MimeType +reading=true +source=true +writing=true +makedir=true +deleting=true +# linking=true +# moving=true +# mimetype=text/plain +# determineMimetypeFromExtension=true +DocPath=tdeioslave/mobile.html +Icon=mobile_camera -- cgit v1.2.1