diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-08-10 06:08:18 +0000 |
commit | 2620ed602b1dc0a7bc3c3135ee12361b1af25405 (patch) | |
tree | 382e1bc273f19af4e5dd261f79741046ed9e37c6 /kradio3/convert-presets/convert-presets.cpp | |
parent | fdd75d807795e8fcf6286df1fb185153ac623efd (diff) | |
download | tderadio-2620ed602b1dc0a7bc3c3135ee12361b1af25405.tar.gz tderadio-2620ed602b1dc0a7bc3c3135ee12361b1af25405.zip |
rename the following methods:
tqfind find
tqreplace replace
tqcontains contains
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kradio@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kradio3/convert-presets/convert-presets.cpp')
-rw-r--r-- | kradio3/convert-presets/convert-presets.cpp | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/kradio3/convert-presets/convert-presets.cpp b/kradio3/convert-presets/convert-presets.cpp index 93e99ea..8ee0d4f 100644 --- a/kradio3/convert-presets/convert-presets.cpp +++ b/kradio3/convert-presets/convert-presets.cpp @@ -64,7 +64,7 @@ bool convertFile(const TQString &file) xmlData = ins.read(); } - if (xmlData.tqfind("<format>", 0, false) >= 0) { + if (xmlData.find("<format>", 0, false) >= 0) { kdDebug() << "file " << file << " already in new format" << endl; // but add <?xml line at beginning if missing @@ -75,7 +75,7 @@ bool convertFile(const TQString &file) xmlData = ins.read(); } - if (xmlData.tqfind("<?xml", 0, false) < 0) { + if (xmlData.find("<?xml", 0, false) < 0) { xmlData = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" + xmlData; } @@ -98,21 +98,21 @@ bool convertFile(const TQString &file) station.setMinimal(true); xmlData = "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n" + xmlData; - xmlData.tqreplace(stationlist, "<stationlist>\n\t\t<format>kradio-1.0</format>"); - xmlData.tqreplace(qselect, ""); - xmlData.tqreplace(docking, ""); - xmlData.tqreplace(station, "<FrequencyRadioStation>\n" + xmlData.replace(stationlist, "<stationlist>\n\t\t<format>kradio-1.0</format>"); + xmlData.replace(qselect, ""); + xmlData.replace(docking, ""); + xmlData.replace(station, "<FrequencyRadioStation>\n" "\t\t\t<" stationIDElement "></" stationIDElement ">" "\\1</FrequencyRadioStation>" ); int p = 0; int f = 0; - while ( (f = xmlData.tqfind("<" stationIDElement "></" stationIDElement ">", p) ) >= 0) { + while ( (f = xmlData.find("<" stationIDElement "></" stationIDElement ">", p) ) >= 0) { xmlData.insert(f + 2 + TQString(stationIDElement).length(), createStationID()); } - xmlData.tqreplace(emptyLines, "\n"); + xmlData.replace(emptyLines, "\n"); } presetFile.close(); |