diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-18 20:34:22 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2011-06-18 20:34:22 +0000 |
commit | b09bffed6b43262948018dfb0f11890850ddf7c1 (patch) | |
tree | 138696bfcc7ac01070d0e8ecaa1cdf94611a2bd8 /kuser/misc.cpp | |
parent | 6d43944a7130b9d1b4ae3fba37b774aced8612cf (diff) | |
download | tdeadmin-b09bffed6b43262948018dfb0f11890850ddf7c1.tar.gz tdeadmin-b09bffed6b43262948018dfb0f11890850ddf7c1.zip |
TQt4 port kdeadmin
This enables compilation under both Qt3 and Qt4
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeadmin@1237416 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kuser/misc.cpp')
-rw-r--r-- | kuser/misc.cpp | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/kuser/misc.cpp b/kuser/misc.cpp index c16f563..5f550be 100644 --- a/kuser/misc.cpp +++ b/kuser/misc.cpp @@ -37,13 +37,13 @@ bool backup(const TQString & name) { - TQString tmp = name + TQString::fromLatin1(KU_BACKUP_EXT); + TQString tmp = name + TQString::tqfromLatin1(KU_BACKUP_EXT); TQFile::remove( tmp ); if (copyFile(TQFile::encodeName(name), TQFile::encodeName(tmp)) == -1) { TQString str; - KMessageBox::error( 0, i18n("Can't create backup file for %1").arg(name) ); + KMessageBox::error( 0, i18n("Can't create backup file for %1").tqarg(name) ); return false; } return true; @@ -68,17 +68,17 @@ int copyFile(const TQString & from, const TQString & to) fo.setName(to); if (!fi.exists()) { - KMessageBox::error( 0, i18n("File %1 does not exist.").arg(from) ); + KMessageBox::error( 0, i18n("File %1 does not exist.").tqarg(from) ); return (-1); } if (!fi.open(IO_ReadOnly)) { - KMessageBox::error( 0, i18n("Cannot open file %1 for reading.").arg(from) ); + KMessageBox::error( 0, i18n("Cannot open file %1 for reading.").tqarg(from) ); return (-1); } if (!fo.open(IO_Raw | IO_WriteOnly | IO_Truncate)) { - KMessageBox::error( 0, i18n("Cannot open file %1 for writing.").arg(to) ); + KMessageBox::error( 0, i18n("Cannot open file %1 for writing.").tqarg(to) ); return (-1); } @@ -120,7 +120,7 @@ TQStringList readShells() void addShell(const TQString &shell) { TQStringList shells = readShells(); - if (shells.contains(shell)) + if (shells.tqcontains(shell)) return; FILE *f = fopen(SHELL_FILE,"a"); @@ -135,7 +135,7 @@ void addShell(const TQString &shell) TQCString genSalt( int len ) { TQCString salt( len + 1 ); - const char * set = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789./"; + const char * set = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPTQRSTUVWXYZ0123456789./"; salt[0] = set[getpid() % strlen(set)]; for( int i = 1; i < len; i++ ) { |