summaryrefslogtreecommitdiffstats
path: root/kdf/disks.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
commit6335dc55802871b5a43492f217b6edbb420204c4 (patch)
tree50c6c8672a52687568edea475614dfe3d98e62e5 /kdf/disks.cpp
parent9b8c9f1f9e974ff0176108cfbd8852cd99ea68c8 (diff)
downloadtdeutils-6335dc55802871b5a43492f217b6edbb420204c4.tar.gz
tdeutils-6335dc55802871b5a43492f217b6edbb420204c4.zip
rename the following methods:
tqfind find tqreplace replace tqcontains contains git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeutils@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdf/disks.cpp')
-rw-r--r--kdf/disks.cpp38
1 files changed, 19 insertions, 19 deletions
diff --git a/kdf/disks.cpp b/kdf/disks.cpp
index 0ae7c2b..721f10d 100644
--- a/kdf/disks.cpp
+++ b/kdf/disks.cpp
@@ -107,10 +107,10 @@ int DiskEntry::mount()
cmdS=TQString::tqfromLatin1("mount -t%t -o%o %d %m");
}
- cmdS.tqreplace(TQString::tqfromLatin1("%d"),deviceName());
- cmdS.tqreplace(TQString::tqfromLatin1("%m"),mountPoint());
- cmdS.tqreplace(TQString::tqfromLatin1("%t"),fsType());
- cmdS.tqreplace(TQString::tqfromLatin1("%o"),mountOptions());
+ cmdS.replace(TQString::tqfromLatin1("%d"),deviceName());
+ cmdS.replace(TQString::tqfromLatin1("%m"),mountPoint());
+ cmdS.replace(TQString::tqfromLatin1("%t"),fsType());
+ cmdS.replace(TQString::tqfromLatin1("%o"),mountOptions());
kdDebug() << "mount-cmd: [" << cmdS << "]" << endl;
int e=sysCall(cmdS);
@@ -126,8 +126,8 @@ int DiskEntry::umount()
if (cmdS.isEmpty()) // generate default umount cmd
cmdS="umount %d";
- cmdS.tqreplace(TQString::tqfromLatin1("%d"),deviceName());
- cmdS.tqreplace(TQString::tqfromLatin1("%m"),mountPoint());
+ cmdS.replace(TQString::tqfromLatin1("%d"),deviceName());
+ cmdS.replace(TQString::tqfromLatin1("%m"),mountPoint());
kdDebug() << "umount-cmd: [" << cmdS << "]" << endl;
int e=sysCall(cmdS);
@@ -193,23 +193,23 @@ TQString DiskEntry::guessIconName()
{
TQString iconName;
// try to be intelligent
- if (-1!=mountPoint().tqfind("cdrom",0,FALSE)) iconName+="cdrom";
- else if (-1!=deviceName().tqfind("cdrom",0,FALSE)) iconName+="cdrom";
- else if (-1!=mountPoint().tqfind("writer",0,FALSE)) iconName+="cdwriter";
- else if (-1!=deviceName().tqfind("writer",0,FALSE)) iconName+="cdwriter";
- else if (-1!=mountPoint().tqfind("mo",0,FALSE)) iconName+="mo";
- else if (-1!=deviceName().tqfind("mo",0,FALSE)) iconName+="mo";
- else if (-1!=deviceName().tqfind("fd",0,FALSE)) {
- if (-1!=deviceName().tqfind("360",0,FALSE)) iconName+="5floppy";
- if (-1!=deviceName().tqfind("1200",0,FALSE)) iconName+="5floppy";
+ if (-1!=mountPoint().find("cdrom",0,FALSE)) iconName+="cdrom";
+ else if (-1!=deviceName().find("cdrom",0,FALSE)) iconName+="cdrom";
+ else if (-1!=mountPoint().find("writer",0,FALSE)) iconName+="cdwriter";
+ else if (-1!=deviceName().find("writer",0,FALSE)) iconName+="cdwriter";
+ else if (-1!=mountPoint().find("mo",0,FALSE)) iconName+="mo";
+ else if (-1!=deviceName().find("mo",0,FALSE)) iconName+="mo";
+ else if (-1!=deviceName().find("fd",0,FALSE)) {
+ if (-1!=deviceName().find("360",0,FALSE)) iconName+="5floppy";
+ if (-1!=deviceName().find("1200",0,FALSE)) iconName+="5floppy";
else iconName+="3floppy";
}
- else if (-1!=mountPoint().tqfind("floppy",0,FALSE)) iconName+="3floppy";
- else if (-1!=mountPoint().tqfind("zip",0,FALSE)) iconName+="zip";
- else if (-1!=fsType().tqfind("nfs",0,FALSE)) iconName+="nfs";
+ else if (-1!=mountPoint().find("floppy",0,FALSE)) iconName+="3floppy";
+ else if (-1!=mountPoint().find("zip",0,FALSE)) iconName+="zip";
+ else if (-1!=fsType().find("nfs",0,FALSE)) iconName+="nfs";
else iconName+="hdd";
mounted() ? iconName+="_mount" : iconName+="_unmount";
-// if ( -1==mountOptions().tqfind("user",0,FALSE) )
+// if ( -1==mountOptions().find("user",0,FALSE) )
// iconName.prepend("root_"); // special root icon, normal user canīt mount
//debug("device %s is %s",deviceName().latin1(),iconName.latin1());