summaryrefslogtreecommitdiffstats
path: root/kppp/connect.cpp
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
commit937b2991d8e78166eea904c80ad04d34607017a4 (patch)
tree2accb8161eab09df5d7a5484ea9ea080ad123168 /kppp/connect.cpp
parentdba26cb985af370c33d1767037851705cc561726 (diff)
downloadtdenetwork-937b2991d8e78166eea904c80ad04d34607017a4.tar.gz
tdenetwork-937b2991d8e78166eea904c80ad04d34607017a4.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kppp/connect.cpp')
-rw-r--r--kppp/connect.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/kppp/connect.cpp b/kppp/connect.cpp
index bb2c17a2..b02da8db 100644
--- a/kppp/connect.cpp
+++ b/kppp/connect.cpp
@@ -425,7 +425,7 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
return;
}
- if(readbuffer.tqcontains(gpppdata.modemBusyResp())) {
+ if(readbuffer.contains(gpppdata.modemBusyResp())) {
timeout_timer->stop();
timeout_timer->start(gpppdata.modemTimeout()*1000);
@@ -451,7 +451,7 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
return;
}
- if(readbuffer.tqcontains(gpppdata.modemNoDialtoneResp())) {
+ if(readbuffer.contains(gpppdata.modemNoDialtoneResp())) {
timeout_timer->stop();
messg->setText(i18n("No Dial Tone"));
@@ -461,7 +461,7 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
return;
}
- if(readbuffer.tqcontains(gpppdata.modemNoCarrierResp())) {
+ if(readbuffer.contains(gpppdata.modemNoCarrierResp())) {
if (gpppdata.get_redial_on_nocarrier()) {
timeout_timer->stop();
timeout_timer->start(gpppdata.modemTimeout()*1000);
@@ -492,7 +492,7 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
return;
}
- if(readbuffer.tqcontains(gpppdata.modemDLPResp())) {
+ if(readbuffer.contains(gpppdata.modemDLPResp())) {
timeout_timer->stop();
messg->setText(i18n("Digital Line Protection Detected."));
@@ -583,12 +583,12 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
if (scriptCommand == "Send" || scriptCommand == "SendNoEcho") {
TQString bm = i18n("Sending %1");
- // tqreplace %USERNAME% and %PASSWORD%
+ // replace %USERNAME% and %PASSWORD%
TQString arg = scriptArgument;
TQRegExp re1("%USERNAME%");
TQRegExp re2("%PASSWORD%");
- arg = arg.tqreplace(re1, gpppdata.storedUsername());
- arg = arg.tqreplace(re2, gpppdata.storedPassword());
+ arg = arg.replace(re1, gpppdata.storedUsername());
+ arg = arg.replace(re2, gpppdata.storedPassword());
if (scriptCommand == "Send")
bm = bm.tqarg(scriptArgument);
@@ -752,7 +752,7 @@ void ConnectWidget::timerEvent(TQTimerEvent *) {
// variable (from the subsequent scan).
TQString ts = scriptArgument;
- int vstart = ts.tqfind( "##" );
+ int vstart = ts.find( "##" );
if( vstart != -1 ) {
ts.remove( vstart, 2 );
ts.insert( vstart, scanvar );
@@ -994,11 +994,11 @@ void ConnectWidget::checkBuffers() {
// Let's check if we are finished with scanning:
// The scanstring have to be in the buffer and the latest character
// was a carriage return or an linefeed (depending on modem setup)
- if( scanning && scanbuffer.tqcontains(scanstr) &&
+ if( scanning && scanbuffer.contains(scanstr) &&
( scanbuffer.right(1) == "\n" || scanbuffer.right(1) == "\r") ) {
scanning = false;
- int vstart = scanbuffer.tqfind( scanstr ) + scanstr.length();
+ int vstart = scanbuffer.find( scanstr ) + scanstr.length();
scanvar = scanbuffer.mid( vstart, scanbuffer.length() - vstart);
scanvar = scanvar.stripWhiteSpace();
@@ -1008,10 +1008,10 @@ void ConnectWidget::checkBuffers() {
}
if(expecting) {
- if(readbuffer.tqcontains(expectstr)) {
+ if(readbuffer.contains(expectstr)) {
expecting = false;
// keep everything after the expected string
- readbuffer.remove(0, readbuffer.tqfind(expectstr) + expectstr.length());
+ readbuffer.remove(0, readbuffer.find(expectstr) + expectstr.length());
TQString ts = i18n("Found: %1").tqarg(expectstr);
emit debugMessage(ts);
@@ -1021,7 +1021,7 @@ void ConnectWidget::checkBuffers() {
}
}
- if (loopend && readbuffer.tqcontains(loopstr[loopnest])) {
+ if (loopend && readbuffer.contains(loopstr[loopnest])) {
expecting = false;
readbuffer = "";
TQString ts = i18n("Looping: %1").tqarg(loopstr[loopnest]);
@@ -1127,7 +1127,7 @@ void ConnectWidget::setExpect(const TQString &n) {
expectstr = n;
TQString ts = i18n("Expecting: %1").tqarg(n);
- ts.tqreplace(TQRegExp("\n"), "<LF>");
+ ts.replace(TQRegExp("\n"), "<LF>");
emit debugMessage(ts);
// check if the expected string is in the read buffer already.
@@ -1382,7 +1382,7 @@ void auto_hostname() {
if (hostname_entry != 0L) {
new_hostname=hostname_entry->h_name;
- dot=new_hostname.tqfind('.');
+ dot=new_hostname.find('.');
new_hostname=new_hostname.remove(dot,new_hostname.length()-dot);
Requester::rq->setHostname(new_hostname);
modified_hostname = TRUE;
@@ -1427,11 +1427,11 @@ void add_domain(const TQString &domain) {
write(fd, tmp.data(), tmp.length());
for(int j=0; j < i; j++) {
- if((resolv[j].tqcontains("domain") ||
- ( resolv[j].tqcontains("nameserver")
- && !resolv[j].tqcontains("#kppp temp entry")
+ if((resolv[j].contains("domain") ||
+ ( resolv[j].contains("nameserver")
+ && !resolv[j].contains("#kppp temp entry")
&& gpppdata.exDNSDisabled()))
- && !resolv[j].tqcontains("#entry disabled by kppp")) {
+ && !resolv[j].contains("#entry disabled by kppp")) {
TQCString tmp = "# " + resolv[j].local8Bit() +
" \t#entry disabled by kppp\n";
write(fd, tmp, tmp.length());
@@ -1510,8 +1510,8 @@ void removedns() {
if((fd = Requester::rq->openResolv(O_WRONLY|O_TRUNC)) >= 0) {
for(int j=0; j < i; j++) {
- if(resolv[j].tqcontains("#kppp temp entry")) continue;
- if(resolv[j].tqcontains("#entry disabled by kppp")) {
+ if(resolv[j].contains("#kppp temp entry")) continue;
+ if(resolv[j].contains("#entry disabled by kppp")) {
TQCString tmp = resolv[j].local8Bit();
write(fd, tmp.data()+2, tmp.length() - 27);
write(fd, "\n", 1);