summaryrefslogtreecommitdiffstats
path: root/kioslave/file/file.cc
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-03 04:12:51 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-03 04:12:51 +0000
commit560378aaca1784ba19806a0414a32b20c744de39 (patch)
treece0dfd7c3febf2a1adc7603d1019a8be2083c415 /kioslave/file/file.cc
parentd4d5af1cdbd3cc65d095e0afc5b1f4260091cf5d (diff)
downloadtdelibs-560378aaca1784ba19806a0414a32b20c744de39.tar.gz
tdelibs-560378aaca1784ba19806a0414a32b20c744de39.zip
Automated conversion for enhanced compatibility with TQt for Qt4 3.4.0 TP1
NOTE: This will not compile with Qt4 (yet), however it does compile with Qt3 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1211081 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kioslave/file/file.cc')
-rw-r--r--kioslave/file/file.cc46
1 files changed, 23 insertions, 23 deletions
diff --git a/kioslave/file/file.cc b/kioslave/file/file.cc
index 441d03b98..31eb5f082 100644
--- a/kioslave/file/file.cc
+++ b/kioslave/file/file.cc
@@ -379,7 +379,7 @@ void FileProtocol::put( const KURL& url, int _mode, bool _overwrite, bool _resum
kdDebug(7101) << "put(): " << dest_orig << ", mode=" << _mode << endl;
TQString dest_part( dest_orig );
- dest_part += TQString::fromLatin1(".part");
+ dest_part += TQString::tqfromLatin1(".part");
TQCString _dest_part( TQFile::encodeName(dest_part));
KDE_struct_stat buff_orig;
@@ -809,7 +809,7 @@ void FileProtocol::copy( const KURL &src, const KURL &dest,
ut.modtime = buff_src.st_mtime;
if ( ::utime( _dest.data(), &ut ) != 0 )
{
- kdWarning() << TQString::fromLatin1("Couldn't preserve access and modification time for\n%1").arg( dest.path() ) << endl;
+ kdWarning() << TQString::tqfromLatin1("Couldn't preserve access and modification time for\n%1").arg( dest.path() ) << endl;
}
processedSize( buff_src.st_size );
@@ -859,7 +859,7 @@ void FileProtocol::rename( const KURL &src, const KURL &dest,
error( KIO::ERR_ACCESS_DENIED, dest.path() );
}
else if (errno == EXDEV) {
- error( KIO::ERR_UNSUPPORTED_ACTION, TQString::fromLatin1("rename"));
+ error( KIO::ERR_UNSUPPORTED_ACTION, TQString::tqfromLatin1("rename"));
}
else if (errno == EROFS) { // The file is on a read-only filesystem
error( KIO::ERR_CANNOT_DELETE, src.path() );
@@ -960,12 +960,12 @@ void FileProtocol::del( const KURL& url, bool isfile)
TQString FileProtocol::getUserName( uid_t uid )
{
TQString *temp;
- temp = usercache.find( uid );
+ temp = usercache.tqfind( uid );
if ( !temp ) {
struct passwd *user = getpwuid( uid );
if ( user ) {
- usercache.insert( uid, new TQString(TQString::fromLatin1(user->pw_name)) );
- return TQString::fromLatin1( user->pw_name );
+ usercache.insert( uid, new TQString(TQString::tqfromLatin1(user->pw_name)) );
+ return TQString::tqfromLatin1( user->pw_name );
}
else
return TQString::number( uid );
@@ -977,12 +977,12 @@ TQString FileProtocol::getUserName( uid_t uid )
TQString FileProtocol::getGroupName( gid_t gid )
{
TQString *temp;
- temp = groupcache.find( gid );
+ temp = groupcache.tqfind( gid );
if ( !temp ) {
struct group *grp = getgrgid( gid );
if ( grp ) {
- groupcache.insert( gid, new TQString(TQString::fromLatin1(grp->gr_name)) );
- return TQString::fromLatin1( grp->gr_name );
+ groupcache.insert( gid, new TQString(TQString::tqfromLatin1(grp->gr_name)) );
+ return TQString::tqfromLatin1( grp->gr_name );
}
else
return TQString::number( gid );
@@ -1116,7 +1116,7 @@ void FileProtocol::stat( const KURL & url )
*/
TQCString _path( TQFile::encodeName(url.path(-1)));
- TQString sDetails = metaData(TQString::fromLatin1("details"));
+ TQString sDetails = metaData(TQString::tqfromLatin1("details"));
int details = sDetails.isEmpty() ? 2 : sDetails.toInt();
kdDebug(7101) << "FileProtocol::stat details=" << details << endl;
@@ -1303,7 +1303,7 @@ void FileProtocol::special( const TQByteArray &data)
case 1:
{
TQString fstype, dev, point;
- Q_INT8 iRo;
+ TQ_INT8 iRo;
stream >> iRo >> fstype >> dev >> point;
@@ -1419,13 +1419,13 @@ void FileProtocol::mount( bool _ro, const char *_fstype, const TQString& _dev, c
bool fstype_empty = !_fstype || !*_fstype;
TQCString fstype = KProcess::quote(_fstype).latin1(); // good guess
TQCString readonly = _ro ? "-r" : "";
- TQString epath = TQString::fromLatin1(getenv("PATH"));
- TQString path = TQString::fromLatin1("/sbin:/bin");
+ TQString epath = TQString::tqfromLatin1(getenv("PATH"));
+ TQString path = TQString::tqfromLatin1("/sbin:/bin");
if(!epath.isEmpty())
- path += TQString::fromLatin1(":") + epath;
+ path += TQString::tqfromLatin1(":") + epath;
TQString mountProg = KGlobal::dirs()->findExe("mount", path);
if (mountProg.isEmpty()){
- error( KIO::ERR_COULD_NOT_MOUNT, i18n("Could not find program \"mount\""));
+ error( KIO::ERR_COULD_NOT_MOUNT, i18n("Could not tqfind program \"mount\""));
return;
}
@@ -1472,7 +1472,7 @@ void FileProtocol::mount( bool _ro, const char *_fstype, const TQString& _dev, c
else
{
// Didn't work - or maybe we just got a warning
- TQString mp = KIO::findDeviceMountPoint( _dev );
+ TQString mp = KIO::tqfindDeviceMountPoint( _dev );
// Is the device mounted ?
if ( !mp.isEmpty() && mount_ret == 0)
{
@@ -1543,7 +1543,7 @@ void FileProtocol::unmount( const TQString& _point )
/*
* since there's no way to derive the device name from
* the mount point through the volmgt library (and
- * media_findname() won't work in this case), we have to
+ * media_tqfindname() won't work in this case), we have to
* look ourselves...
*/
devname = NULL;
@@ -1604,13 +1604,13 @@ void FileProtocol::unmount( const TQString& _point )
}
#else
TQString epath = getenv("PATH");
- TQString path = TQString::fromLatin1("/sbin:/bin");
+ TQString path = TQString::tqfromLatin1("/sbin:/bin");
if (!epath.isEmpty())
path += ":" + epath;
TQString umountProg = KGlobal::dirs()->findExe("umount", path);
if (umountProg.isEmpty()) {
- error( KIO::ERR_COULD_NOT_UNMOUNT, i18n("Could not find program \"umount\""));
+ error( KIO::ERR_COULD_NOT_UNMOUNT, i18n("Could not tqfind program \"umount\""));
return;
}
buffer.sprintf( "%s %s 2>%s", umountProg.latin1(), TQFile::encodeName(KProcess::quote(_point)).data(), tmp );
@@ -1619,7 +1619,7 @@ void FileProtocol::unmount( const TQString& _point )
err = testLogFile( tmp );
- if (err.contains("fstab") || err.contains("root")) {
+ if (err.tqcontains("fstab") || err.tqcontains("root")) {
TQString olderr;
err = TQString::null;
@@ -1658,7 +1658,7 @@ void FileProtocol::unmount( const TQString& _point )
bool FileProtocol::pmount(const TQString &dev)
{
TQString epath = getenv("PATH");
- TQString path = TQString::fromLatin1("/sbin:/bin");
+ TQString path = TQString::tqfromLatin1("/sbin:/bin");
if (!epath.isEmpty())
path += ":" + epath;
TQString pmountProg = KGlobal::dirs()->findExe("pmount", path);
@@ -1700,7 +1700,7 @@ bool FileProtocol::pumount(const TQString &point)
if (dev.endsWith("/")) dev.truncate(dev.length()-1);
TQString epath = getenv("PATH");
- TQString path = TQString::fromLatin1("/sbin:/bin");
+ TQString path = TQString::tqfromLatin1("/sbin:/bin");
if (!epath.isEmpty())
path += ":" + epath;
TQString pumountProg = KGlobal::dirs()->findExe("pumount", path);
@@ -1774,7 +1774,7 @@ static bool isExtendedACL( acl_t acl )
static TQString aclAsString( acl_t acl )
{
char *aclString = acl_to_text( acl, 0 );
- TQString ret = TQString::fromLatin1( aclString );
+ TQString ret = TQString::tqfromLatin1( aclString );
acl_free( (void*)aclString );
return ret;
}