diff options
author | Timothy Pearson <[email protected]> | 2011-12-16 09:56:31 -0600 |
---|---|---|
committer | Timothy Pearson <[email protected]> | 2011-12-16 09:56:31 -0600 |
commit | c9cb4f487428aad5d8cda5e3a4b9ad87390d7e54 (patch) | |
tree | 1ee1912ac4bb966475f0db0f2a78678661b4b4a5 /kexi/kexidb/drivers/sqlite | |
parent | 94844816550ad672ccfcdc25659c625546239998 (diff) | |
download | koffice-c9cb4f487428aad5d8cda5e3a4b9ad87390d7e54.tar.gz koffice-c9cb4f487428aad5d8cda5e3a4b9ad87390d7e54.zip |
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit 94844816550ad672ccfcdc25659c625546239998.
Diffstat (limited to 'kexi/kexidb/drivers/sqlite')
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqliteadmin.cpp | 2 | ||||
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqliteconnection.cpp | 16 | ||||
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqlitecursor.cpp | 14 | ||||
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqlitevacuum.cpp | 4 |
4 files changed, 18 insertions, 18 deletions
diff --git a/kexi/kexidb/drivers/sqlite/sqliteadmin.cpp b/kexi/kexidb/drivers/sqlite/sqliteadmin.cpp index 1fb33233..14d2217a 100644 --- a/kexi/kexidb/drivers/sqlite/sqliteadmin.cpp +++ b/kexi/kexidb/drivers/sqlite/sqliteadmin.cpp @@ -46,7 +46,7 @@ bool SQLiteAdminTools::vacuum(const KexiDB::ConnectionData& data, const TQString #else KexiDB::DriverManager manager; KexiDB::Driver *drv = manager.driver(data.driverName); - TQString title( i18n("Could not compact database \"%1\".").arg(TQDir::convertSeparators(databaseName)) ); + TQString title( i18n("Could not compact database \"%1\".").tqarg(TQDir::convertSeparators(databaseName)) ); if (!drv) { setError(&manager, title); return false; diff --git a/kexi/kexidb/drivers/sqlite/sqliteconnection.cpp b/kexi/kexidb/drivers/sqlite/sqliteconnection.cpp index cf478b94..631f3bc6 100644 --- a/kexi/kexidb/drivers/sqlite/sqliteconnection.cpp +++ b/kexi/kexidb/drivers/sqlite/sqliteconnection.cpp @@ -130,7 +130,7 @@ bool SQLiteConnection::drv_containsTable( const TQString &tableName ) { bool success; return resultExists(TQString("select name from sqlite_master where type='table' and name LIKE %1") - .arg(driver()->escapeString(tableName)), success) && success; + .tqarg(driver()->escapeString(tableName)), success) && success; } bool SQLiteConnection::drv_getTablesList( TQStringList &list ) @@ -188,7 +188,7 @@ bool SQLiteConnection::drv_useDatabase( const TQString &dbName, bool *cancelled, d->res = sqlite3_open( //TQFile::encodeName( data()->fileName() ), - data()->fileName().utf8(), /* unicode expected since SQLite 3.1 */ + data()->fileName().utf8(), /* tqunicode expected since SQLite 3.1 */ &d->data, exclusiveFlag, allowReadonly /* If 1 and locking fails, try opening in read-only mode */ @@ -200,7 +200,7 @@ bool SQLiteConnection::drv_useDatabase( const TQString &dbName, bool *cancelled, if (KMessageBox::Continue != askQuestion( i18n("Do you want to open file \"%1\" as read-only?") - .arg(TQDir::convertSeparators(data()->fileName())) + .tqarg(TQDir::convertSeparators(data()->fileName())) + "\n\n" + i18n("The file is probably already open on this or another computer.") + " " + i18n("Could not gain exclusive access for writing the file."), @@ -264,7 +264,7 @@ bool SQLiteConnection::drv_dropDatabase( const TQString &dbName ) const TQString filename = data()->fileName(); if (TQFile(filename).exists() && !TQDir().remove(filename)) { setError(ERR_ACCESS_RIGHTS, i18n("Could not remove file \"%1\".") - .arg(TQDir::convertSeparators(filename)) + " " + .tqarg(TQDir::convertSeparators(filename)) + " " + i18n("Check the file's permissions and whether it is already opened and locked by another application.")); return false; } @@ -324,9 +324,9 @@ TQString SQLiteConnection::serverResultName() { TQString r = #ifdef SQLITE2 - TQString::fromLatin1( sqlite_error_string(d->res) ); + TQString::tqfromLatin1( sqlite_error_string(d->res) ); #else //SQLITE3 - TQString(); //fromLatin1( d->result_name ); + TQString(); //tqfromLatin1( d->result_name ); #endif return r.isEmpty() ? Connection::serverResultName() : r; } @@ -395,8 +395,8 @@ bool SQLiteConnection::drv_alterTableName(TableSchema& tableSchema, const TQStri //TODO indices, etc.??? // 3. copy all rows to the new table - if (!executeSQL(TQString::fromLatin1("INSERT INTO %1 SELECT * FROM %2") - .arg(escapeIdentifier(tableSchema.name())).arg(escapeIdentifier(oldTableName)))) + if (!executeSQL(TQString::tqfromLatin1("INSERT INTO %1 SELECT * FROM %2") + .tqarg(escapeIdentifier(tableSchema.name())).tqarg(escapeIdentifier(oldTableName)))) { drv_alterTableName_ERR; return false; diff --git a/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp b/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp index 20d80f9c..5239127c 100644 --- a/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp +++ b/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp @@ -476,19 +476,19 @@ void SQLiteCursor::storeCurrentRow(RowData &data) const case Field::Integer: data[i] = TQVariant( TQCString(*col).toInt() ); case Field::BigInteger: - data[i] = TQVariant( TQString::fromLatin1(*col).toLongLong() ); + data[i] = TQVariant( TQString::tqfromLatin1(*col).toLongLong() ); case Field::Boolean: - data[i] = TQVariant( sqliteStringToBool(TQString::fromLatin1(*col)), 1 ); + data[i] = TQVariant( sqliteStringToBool(TQString::tqfromLatin1(*col)), 1 ); break; case Field::Date: - data[i] = TQDate::fromString( TQString::fromLatin1(*col), Qt::ISODate ); + data[i] = TQDate::fromString( TQString::tqfromLatin1(*col), Qt::ISODate ); break; case Field::Time: //TQDateTime - a hack needed because TQVariant(TQTime) has broken isNull() - data[i] = KexiUtils::stringToHackedTQTime(TQString::fromLatin1(*col)); + data[i] = KexiUtils::stringToHackedTQTime(TQString::tqfromLatin1(*col)); break; case Field::DateTime: { - TQString tmp( TQString::fromLatin1(*col) ); + TQString tmp( TQString::tqfromLatin1(*col) ); tmp[10] = 'T'; data[i] = TQDateTime::fromString( tmp, Qt::ISODate ); break; @@ -548,9 +548,9 @@ int SQLiteCursor::serverResult() TQString SQLiteCursor::serverResultName() { #ifdef SQLITE2 - return TQString::fromLatin1( sqlite_error_string(d->res) ); + return TQString::tqfromLatin1( sqlite_error_string(d->res) ); #else //SQLITE3 - return TQString::fromLatin1( d->result_name ); + return TQString::tqfromLatin1( d->result_name ); #endif } diff --git a/kexi/kexidb/drivers/sqlite/sqlitevacuum.cpp b/kexi/kexidb/drivers/sqlite/sqlitevacuum.cpp index 96802596..d24d906d 100644 --- a/kexi/kexidb/drivers/sqlite/sqlitevacuum.cpp +++ b/kexi/kexidb/drivers/sqlite/sqlitevacuum.cpp @@ -79,7 +79,7 @@ tristate SQLiteVacuum::run() } m_dlg = new KProgressDialog(0, 0, i18n("Compacting database"), "<qt>"+i18n("Compacting database \"%1\"...") - .arg("<nobr>"+TQDir::convertSeparators(TQFileInfo(m_filePath).fileName())+"</nobr>") + .tqarg("<nobr>"+TQDir::convertSeparators(TQFileInfo(m_filePath).fileName())+"</nobr>") ); m_dlg->adjustSize(); m_dlg->resize(300, m_dlg->height()); @@ -98,7 +98,7 @@ tristate SQLiteVacuum::run() const uint newSize = TQFileInfo(m_filePath).size(); const uint decrease = 100-100*newSize/origSize; KMessageBox::information(0, i18n("The database has been compacted. Current size decreased by %1% to %2.") - .arg(decrease).arg(KIO::convertSize(newSize))); + .tqarg(decrease).tqarg(KIO::convertSize(newSize))); } return m_result; } |