diff options
Diffstat (limited to 'kfile-plugins')
-rw-r--r-- | kfile-plugins/cert/kfile_cert.cpp | 4 | ||||
-rw-r--r-- | kfile-plugins/html/kfile_html.cpp | 2 | ||||
-rw-r--r-- | kfile-plugins/lnk/lnkforward.cpp | 2 | ||||
-rw-r--r-- | kfile-plugins/mhtml/kfile_mhtml.cpp | 28 |
4 files changed, 18 insertions, 18 deletions
diff --git a/kfile-plugins/cert/kfile_cert.cpp b/kfile-plugins/cert/kfile_cert.cpp index 4175240..3ffd163 100644 --- a/kfile-plugins/cert/kfile_cert.cpp +++ b/kfile-plugins/cert/kfile_cert.cpp @@ -110,10 +110,10 @@ static KSSLCertificate *readCertFromFile(const TQString &path) KOSSL::self()->ERR_clear_error(); const char *begin_line = "-----BEGIN CERTIFICATE-----\n"; const char *end_line = "\n-----END CERTIFICATE-----"; - int begin_pos = file_string.tqfind(begin_line); + int begin_pos = file_string.find(begin_line); if (begin_pos >= 0) { begin_pos += strlen(begin_line); - int end_pos = file_string.tqfind(end_line, begin_pos); + int end_pos = file_string.find(end_line, begin_pos); if (end_pos >= 0) { // read the data between begin and end lines TQCString body = file_string.mid(begin_pos, end_pos - begin_pos); diff --git a/kfile-plugins/html/kfile_html.cpp b/kfile-plugins/html/kfile_html.cpp index d49d184..3711e46 100644 --- a/kfile-plugins/html/kfile_html.cpp +++ b/kfile-plugins/html/kfile_html.cpp @@ -151,7 +151,7 @@ bool KHtmlPlugin::readInfo( KFileMetaInfo& info, uint ) // find out if it contains javascript exp.setPattern("<script>"); - appendItem(group, "Javascript", TQVariant( s.tqfind(exp)!=-1, 42)); + appendItem(group, "Javascript", TQVariant( s.find(exp)!=-1, 42)); return true; } diff --git a/kfile-plugins/lnk/lnkforward.cpp b/kfile-plugins/lnk/lnkforward.cpp index 9eb6af0..af4492b 100644 --- a/kfile-plugins/lnk/lnkforward.cpp +++ b/kfile-plugins/lnk/lnkforward.cpp @@ -72,7 +72,7 @@ int LNKForwarder::run(KCmdLineArgs *args) bool ret = readLNK(args->arg(0), info); if ( ! ret ) return 1; - info.path.tqreplace(TQChar('\\'), TQChar('/')); + info.path.replace(TQChar('\\'), TQChar('/')); TQString path; diff --git a/kfile-plugins/mhtml/kfile_mhtml.cpp b/kfile-plugins/mhtml/kfile_mhtml.cpp index 96da46e..895d969 100644 --- a/kfile-plugins/mhtml/kfile_mhtml.cpp +++ b/kfile-plugins/mhtml/kfile_mhtml.cpp @@ -120,21 +120,21 @@ bool mhtmlPlugin::readInfo( KFileMetaInfo& info, uint /*what*/) } TQString mhtmlPlugin::decodeRFC2047Phrase(const TQString &msg, bool removeLessGreater){ - int st=msg.tqfind("=?"); + int st=msg.find("=?"); int en=-1; TQString msgCopy=msg; TQString decodedText=msgCopy.left(st); TQString encodedText=msgCopy.mid(st); - st=encodedText.tqfind("=?"); + st=encodedText.find("=?"); while(st!=-1){ - en=encodedText.tqfind("?="); - while(encodedText.mid(en+2,1)!=" " && en+2<(int)encodedText.length()) en=encodedText.tqfind("?=",en+1); + en=encodedText.find("?="); + while(encodedText.mid(en+2,1)!=" " && en+2<(int)encodedText.length()) en=encodedText.find("?=",en+1); if(en==-1) break; decodedText+=encodedText.left(st); TQString tmp=encodedText.mid(st,en-st+2); encodedText=encodedText.mid(en+2); decodedText+=decodeRFC2047String(tmp); - st=encodedText.tqfind("=?",st+1); + st=encodedText.find("=?",st+1); } decodedText += encodedText; // remove unwanted '<' and '>' @@ -147,12 +147,12 @@ TQString mhtmlPlugin::decodeRFC2047Phrase(const TQString &msg, bool removeLessGr TQString dec=decodedText; TQString tmp; - st=decodedText.tqfind("<"); + st=decodedText.find("<"); while(st!=-1){ - st=dec.tqfind("<",st); + st=dec.find("<",st); if(st==0 || (st!=0 && (dec.mid(st-2,2)==", "))){ - en=dec.tqfind(">",st); - if(en==-1 && dec.tqfind(",",st)<en){ + en=dec.find(">",st); + if(en==-1 && dec.find(",",st)<en){ st++; continue; } @@ -172,17 +172,17 @@ TQString mhtmlPlugin::decodeRFC2047String(const TQString &msg){ TQString encodedText; TQString decodedText; int encEnd=0; - if(msg.startsWith("=?") && (encEnd=msg.tqfindRev("?="))!=-1){ + if(msg.startsWith("=?") && (encEnd=msg.findRev("?="))!=-1){ notEncodedText=msg.mid(encEnd+2); encodedText=msg.left(encEnd); encodedText=encodedText.mid(2,encodedText.length()-2); - int questionMark=encodedText.tqfind('?'); + int questionMark=encodedText.find('?'); if(questionMark==-1) return msg; charset=encodedText.left(questionMark).lower(); encoding=encodedText.mid(questionMark+1,1).lower(); if(encoding!="b" && encoding!="q") return msg; encodedText=encodedText.mid(questionMark+3); - if(charset.tqfind(" ")!=-1 && encodedText.tqfind(" ")!=-1) return msg; + if(charset.find(" ")!=-1 && encodedText.find(" ")!=-1) return msg; TQCString tmpIn; TQCString tmpOut; tmpIn = encodedText.local8Bit(); @@ -192,8 +192,8 @@ TQString mhtmlPlugin::decodeRFC2047String(const TQString &msg){ TQTextCodec *codec = TQTextCodec::codecForName(charset.local8Bit()); if(!codec) return msg; decodedText=codec->toUnicode(tmpOut); - decodedText=decodedText.tqreplace("_"," "); - }else decodedText=tmpOut.tqreplace("_"," "); + decodedText=decodedText.replace("_"," "); + }else decodedText=tmpOut.replace("_"," "); return decodedText + notEncodedText; }else return msg; } |