summaryrefslogtreecommitdiffstats
path: root/kresources/caldav
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-08-10 06:08:18 +0000
commit4c6f8d69e2d1501837affb472c4eb8fec4462240 (patch)
tree766a8ad7939fcf3eec534184c36bd0e0f80489e2 /kresources/caldav
parent469cc56a805bd3d6940d54adbef554877c29853c (diff)
downloadtdepim-4c6f8d69e2d1501837affb472c4eb8fec4462240.tar.gz
tdepim-4c6f8d69e2d1501837affb472c4eb8fec4462240.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdepim@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kresources/caldav')
-rw-r--r--kresources/caldav/preferences.cpp30
-rw-r--r--kresources/caldav/resource.cpp42
2 files changed, 36 insertions, 36 deletions
diff --git a/kresources/caldav/preferences.cpp b/kresources/caldav/preferences.cpp
index 11de07e9..6eb87e45 100644
--- a/kresources/caldav/preferences.cpp
+++ b/kresources/caldav/preferences.cpp
@@ -218,16 +218,16 @@ TQString CalDavPrefs::getFullUrl() {
safeURL = t.toString();
- firstAt = safeURL.tqfind("@") + 1;
- while (safeURL.tqfind("@", firstAt) != -1) {
- safeURL.tqreplace(safeURL.tqfind("@", firstAt), 1, "%40");
+ firstAt = safeURL.find("@") + 1;
+ while (safeURL.find("@", firstAt) != -1) {
+ safeURL.replace(safeURL.find("@", firstAt), 1, "%40");
}
// Unencode the username, as Zimbra stupidly rejects the %40
- safeURL.tqreplace("%40", "@");
+ safeURL.replace("%40", "@");
// Encode any spaces, as libcaldav stupidly fails otherwise
- safeURL.tqreplace(" ", "%20");
+ safeURL.replace(" ", "%20");
return safeURL;
}
@@ -245,16 +245,16 @@ TQString CalDavPrefs::getFullTasksUrl() {
safeURL = t.toString();
- firstAt = safeURL.tqfind("@") + 1;
- while (safeURL.tqfind("@", firstAt) != -1) {
- safeURL.tqreplace(safeURL.tqfind("@", firstAt), 1, "%40");
+ firstAt = safeURL.find("@") + 1;
+ while (safeURL.find("@", firstAt) != -1) {
+ safeURL.replace(safeURL.find("@", firstAt), 1, "%40");
}
// Unencode the username, as Zimbra stupidly rejects the %40
- safeURL.tqreplace("%40", "@");
+ safeURL.replace("%40", "@");
// Encode any spaces, as libcaldav stupidly fails otherwise
- safeURL.tqreplace(" ", "%20");
+ safeURL.replace(" ", "%20");
return safeURL;
}
@@ -272,16 +272,16 @@ TQString CalDavPrefs::getFullJournalsUrl() {
safeURL = t.toString();
- firstAt = safeURL.tqfind("@") + 1;
- while (safeURL.tqfind("@", firstAt) != -1) {
- safeURL.tqreplace(safeURL.tqfind("@", firstAt), 1, "%40");
+ firstAt = safeURL.find("@") + 1;
+ while (safeURL.find("@", firstAt) != -1) {
+ safeURL.replace(safeURL.find("@", firstAt), 1, "%40");
}
// Unencode the username, as Zimbra stupidly rejects the %40
- safeURL.tqreplace("%40", "@");
+ safeURL.replace("%40", "@");
// Encode any spaces, as libcaldav stupidly fails otherwise
- safeURL.tqreplace(" ", "%20");
+ safeURL.replace(" ", "%20");
return safeURL;
}
diff --git a/kresources/caldav/resource.cpp b/kresources/caldav/resource.cpp
index d828037b..db4546d8 100644
--- a/kresources/caldav/resource.cpp
+++ b/kresources/caldav/resource.cpp
@@ -403,8 +403,8 @@ void ResourceCalDav::loadFinished() {
// TODO: I don't know why, but some schedules on http://caldav-test.ioda.net/ (I used it for testing)
// have some lines separated by single \r rather than \n or \r\n.
// ICalFormat fails to parse that.
- data.tqreplace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
- data.tqreplace('\r', '\n');
+ data.replace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
+ data.replace('\r', '\n');
log("trying to parse...");
if (parseData(data)) {
@@ -451,8 +451,8 @@ void ResourceCalDav::loadFinished() {
// TODO: I don't know why, but some schedules on http://caldav-test.ioda.net/ (I used it for testing)
// have some lines separated by single \r rather than \n or \r\n.
// ICalFormat fails to parse that.
- tasksData.tqreplace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
- tasksData.tqreplace('\r', '\n');
+ tasksData.replace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
+ tasksData.replace('\r', '\n');
log("trying to parse...");
if (parseTasksData(tasksData)) {
@@ -499,8 +499,8 @@ void ResourceCalDav::loadFinished() {
// TODO: I don't know why, but some schedules on http://caldav-test.ioda.net/ (I used it for testing)
// have some lines separated by single \r rather than \n or \r\n.
// ICalFormat fails to parse that.
- journalsData.tqreplace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
- journalsData.tqreplace('\r', '\n');
+ journalsData.replace("\r\n", "\n"); // to avoid \r\n becomes \n\n after the next line
+ journalsData.replace('\r', '\n');
log("trying to parse...");
if (parseJournalsData(journalsData)) {
@@ -726,7 +726,7 @@ TQString ResourceCalDav::getICalString(const Incidence::List& inc) {
// Get the iCal header and footer
header = ical.toString(&loc);
- int location = header.tqfind("END:VCALENDAR", 0, true);
+ int location = header.find("END:VCALENDAR", 0, true);
footer = header.mid(location, 0xffffffff);
header.remove("END:VCALENDAR");
@@ -740,13 +740,13 @@ TQString ResourceCalDav::getICalString(const Incidence::List& inc) {
data = data + footer;
// Remove any line feeds/carriage returns/white spaces from the UID field as they WILL break libcaldav
- int uidPos = data.tqfind("UID:", 0) + 4;
- int nextPos = data.tqfindRev("\n", data.tqfind(":", uidPos));
+ int uidPos = data.find("UID:", 0) + 4;
+ int nextPos = data.findRev("\n", data.find(":", uidPos));
TQString uidField = data.mid(uidPos, nextPos-uidPos);
data.remove(uidPos, nextPos-uidPos);
- uidField.tqreplace("\n", "");
- uidField.tqreplace("\r", "");
- uidField.tqreplace(" ", "");
+ uidField.replace("\n", "");
+ uidField.replace("\r", "");
+ uidField.replace(" ", "");
data.insert(uidPos, uidField);
return data;
}
@@ -888,11 +888,11 @@ bool ResourceCalDav::startWriting(const TQString& url, const TQString& tasksUrl,
t->journalsAdded = "";
t->journalsChanged = "";
t->journalsDeleted = "";
- if (getICalString(currentIncidence).tqcontains("BEGIN:VEVENT") > 0)
+ if (getICalString(currentIncidence).contains("BEGIN:VEVENT") > 0)
t->added = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VTODO") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VTODO") > 0)
t->tasksAdded = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VJOURNAL") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VJOURNAL") > 0)
t->journalsAdded = getICalString(currentIncidence);
writingQueuePush(t);
@@ -916,11 +916,11 @@ bool ResourceCalDav::startWriting(const TQString& url, const TQString& tasksUrl,
t->journalsChanged = "";
t->journalsDeleted = "";
- if (getICalString(currentIncidence).tqcontains("BEGIN:VEVENT") > 0)
+ if (getICalString(currentIncidence).contains("BEGIN:VEVENT") > 0)
t->changed = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VTODO") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VTODO") > 0)
t->tasksChanged = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VJOURNAL") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VJOURNAL") > 0)
t->journalsChanged = getICalString(currentIncidence);
writingQueuePush(t);
@@ -944,11 +944,11 @@ bool ResourceCalDav::startWriting(const TQString& url, const TQString& tasksUrl,
t->journalsChanged = "";
t->journalsDeleted = "";
- if (getICalString(currentIncidence).tqcontains("BEGIN:VEVENT") > 0)
+ if (getICalString(currentIncidence).contains("BEGIN:VEVENT") > 0)
t->deleted = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VTODO") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VTODO") > 0)
t->tasksDeleted = getICalString(currentIncidence);
- else if (getICalString(currentIncidence).tqcontains("BEGIN:VJOURNALS") > 0)
+ else if (getICalString(currentIncidence).contains("BEGIN:VJOURNALS") > 0)
t->journalsDeleted = getICalString(currentIncidence);
writingQueuePush(t);