summaryrefslogtreecommitdiffstats
path: root/src/notedrag.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:29:20 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:29:20 -0600
commit882bcd26b3d60be72ea2b35921969a9850c52db9 (patch)
tree8d0a6902c5de4632c4e73e35c4d86404fa75f470 /src/notedrag.cpp
parentc82058b2b64334c10d7e547cb81ac64efe09f516 (diff)
downloadbasket-882bcd26b3d60be72ea2b35921969a9850c52db9.tar.gz
basket-882bcd26b3d60be72ea2b35921969a9850c52db9.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'src/notedrag.cpp')
-rw-r--r--src/notedrag.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/notedrag.cpp b/src/notedrag.cpp
index 5f00918..a7065ed 100644
--- a/src/notedrag.cpp
+++ b/src/notedrag.cpp
@@ -21,7 +21,7 @@
#include <tqdragobject.h>
#include <tqdir.h>
#include <tqpainter.h>
-#include <tqtextcodec.h>
+#include <textcodec.h>
#include <tqbuffer.h>
#include <kurldrag.h>
#include <tdeversion.h>
@@ -227,7 +227,7 @@ void NoteDrag::serializeLinks(NoteSelection *noteList, KMultipleDrag *multipleDr
multipleDrag->addDragObject(urlsDrag);
#else
KURLDrag2 *urlsDrag = new KURLDrag2(urls);
- TQByteArray byteArray = urlsDrag->tqencodedData2("text/uri-list");
+ TQByteArray byteArray = urlsDrag->encodedData2("text/uri-list");
TQStoredDrag *uriListDrag = new TQStoredDrag("text/uri-list");
uriListDrag->setEncodedData(byteArray);
multipleDrag->addDragObject(uriListDrag);
@@ -375,7 +375,7 @@ bool NoteDrag::canDecode(TQMimeSource *source)
Basket* NoteDrag::basketOf(TQMimeSource *source)
{
- TQBuffer buffer(source->tqencodedData(NOTE_MIME_STRING));
+ TQBuffer buffer(source->encodedData(NOTE_MIME_STRING));
if (buffer.open(IO_ReadOnly)) {
TQDataStream stream(&buffer);
// Get the parent basket:
@@ -388,7 +388,7 @@ Basket* NoteDrag::basketOf(TQMimeSource *source)
TQValueList<Note*> NoteDrag::notesOf(TQMimeSource *source)
{
- TQBuffer buffer(source->tqencodedData(NOTE_MIME_STRING));
+ TQBuffer buffer(source->encodedData(NOTE_MIME_STRING));
if (buffer.open(IO_ReadOnly)) {
TQDataStream stream(&buffer);
// Get the parent basket:
@@ -410,7 +410,7 @@ TQValueList<Note*> NoteDrag::notesOf(TQMimeSource *source)
Note* NoteDrag::decode(TQMimeSource *source, Basket *parent, bool moveFiles, bool moveNotes)
{
- TQBuffer buffer(source->tqencodedData(NOTE_MIME_STRING));
+ TQBuffer buffer(source->encodedData(NOTE_MIME_STRING));
if (buffer.open(IO_ReadOnly)) {
TQDataStream stream(&buffer);
// Get the parent basket:
@@ -558,7 +558,7 @@ bool ExtendedTextDrag::decode(const TQMimeSource *e, TQString &str, TQCString &s
// Test if it was a UTF-16 string (from eg. Mozilla):
if (str.length() >= 2) {
if ((str[0] == 0xFF && str[1] == 0xFE) || (str[0] == 0xFE && str[1] == 0xFF)) {
- TQByteArray utf16 = e->tqencodedData(TQString("text/" + subtype).local8Bit());
+ TQByteArray utf16 = e->encodedData(TQString("text/" + subtype).local8Bit());
str = TQTextCodec::codecForName("utf16")->toUnicode(utf16);
return true;
}
@@ -567,22 +567,22 @@ bool ExtendedTextDrag::decode(const TQMimeSource *e, TQString &str, TQCString &s
// Test if it was empty (sometimes, from GNOME or Mozilla)
if (str.length() == 0 && subtype == "plain") {
if (e->provides("UTF8_STRING")) {
- TQByteArray utf8 = e->tqencodedData("UTF8_STRING");
+ TQByteArray utf8 = e->encodedData("UTF8_STRING");
str = TQTextCodec::codecForName("utf8")->toUnicode(utf8);
return true;
}
- if (e->provides("text/tqunicode")) { // FIXME: It's UTF-16 without order bytes!!!
- TQByteArray utf16 = e->tqencodedData("text/tqunicode");
+ if (e->provides("text/unicode")) { // FIXME: It's UTF-16 without order bytes!!!
+ TQByteArray utf16 = e->encodedData("text/unicode");
str = TQTextCodec::codecForName("utf16")->toUnicode(utf16);
return true;
}
if (e->provides("TEXT")) { // local encoding
- TQByteArray text = e->tqencodedData("TEXT");
+ TQByteArray text = e->encodedData("TEXT");
str = TQString(text);
return true;
}
if (e->provides("COMPOUND_TEXT")) { // local encoding
- TQByteArray text = e->tqencodedData("COMPOUND_TEXT");
+ TQByteArray text = e->encodedData("COMPOUND_TEXT");
str = TQString(text);
return true;
}