diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:25:18 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:25:18 +0000 |
commit | aa3a1ca934bc541bddd3fa136a85f106f7da266e (patch) | |
tree | 9ad0b795aed8fa4ac30c2fe0fd1aacb8175714c0 /ksysv/ksvdrag.cpp | |
parent | b10cf7066791a2f362495890cd50c984e8025412 (diff) | |
download | tdeadmin-aa3a1ca934bc541bddd3fa136a85f106f7da266e.tar.gz tdeadmin-aa3a1ca934bc541bddd3fa136a85f106f7da266e.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeadmin@1157635 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksysv/ksvdrag.cpp')
-rw-r--r-- | ksysv/ksvdrag.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/ksysv/ksvdrag.cpp b/ksysv/ksvdrag.cpp index 1f24417..7d94536 100644 --- a/ksysv/ksvdrag.cpp +++ b/ksysv/ksvdrag.cpp @@ -1,7 +1,7 @@ // (c) 2000 Peter Putzer -#include <qstring.h> -#include <qcstring.h> +#include <tqstring.h> +#include <tqcstring.h> #include <kurl.h> @@ -12,27 +12,27 @@ class KSVDrag::Private { public: - QByteArray mNative; - QString mText; + TQByteArray mNative; + TQString mText; KURL mURL; }; -KSVDrag::KSVDrag (const KSVData& item, QWidget* source, const char* name) - : QDragObject (source, name), +KSVDrag::KSVDrag (const KSVData& item, TQWidget* source, const char* name) + : TQDragObject (source, name), d (new Private()) { - QDataStream ds (d->mNative, IO_ReadWrite); + TQDataStream ds (d->mNative, IO_ReadWrite); ds << item; d->mText = item.filenameAndPath (); d->mURL.setPath (item.path() + "/" + item.filename()); } -KSVDrag::KSVDrag (const KSVItem& item, QWidget* source, const char* name) - : QDragObject (source, name), +KSVDrag::KSVDrag (const KSVItem& item, TQWidget* source, const char* name) + : TQDragObject (source, name), d (new Private()) { - QDataStream ds (d->mNative, IO_ReadWrite); + TQDataStream ds (d->mNative, IO_ReadWrite); ds << *item.data(); d->mText = item.toString(); @@ -65,9 +65,9 @@ const char* KSVDrag::format (int i) const } } -QByteArray KSVDrag::encodedData (const char* format) const +TQByteArray KSVDrag::encodedData (const char* format) const { - QByteArray res; + TQByteArray res; if (!strcmp (format, "application/x-ksysv")) { @@ -75,22 +75,22 @@ QByteArray KSVDrag::encodedData (const char* format) const } else if (!strcmp (format, "text/plain")) { - QDataStream ds (res, IO_ReadWrite); + TQDataStream ds (res, IO_ReadWrite); ds << d->mText; } else if (!strcmp (format, "text/uri-list")) { - res = QCString(d->mURL.url().latin1()).copy(); + res = TQCString(d->mURL.url().latin1()).copy(); } return res; } -bool KSVDrag::decodeNative (const QMimeSource* mime, KSVData& data) +bool KSVDrag::decodeNative (const TQMimeSource* mime, KSVData& data) { if (mime && mime->provides ("application/x-ksysv")) { - QDataStream ds (mime->encodedData ("application/x-ksysv"), IO_ReadOnly); + TQDataStream ds (mime->encodedData ("application/x-ksysv"), IO_ReadOnly); ds >> data; return true; |