diff options
author | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-11-05 11:54:26 +0900 |
---|---|---|
committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2023-11-16 23:37:57 +0900 |
commit | ef06f14f2475bd08d3ea2ceec54a7b2238f3554e (patch) | |
tree | 03df826633e4ba084d133ca977c4fc37c74f21ac /kexi/kexidb | |
parent | 895081803a715ee89f4a90cfbf63d558ef2b2ebc (diff) | |
download | koffice-ef06f14f2475bd08d3ea2ceec54a7b2238f3554e.tar.gz koffice-ef06f14f2475bd08d3ea2ceec54a7b2238f3554e.zip |
Replace Qt with TQt
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'kexi/kexidb')
-rw-r--r-- | kexi/kexidb/driver.cpp | 4 | ||||
-rw-r--r-- | kexi/kexidb/driver.h | 4 | ||||
-rw-r--r-- | kexi/kexidb/drivers/mySQL/mysqlpreparedstatement.cpp | 6 | ||||
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqlitecursor.cpp | 8 | ||||
-rw-r--r-- | kexi/kexidb/drivers/sqlite/sqlitepreparedstatement.cpp | 6 | ||||
-rw-r--r-- | kexi/kexidb/expression.cpp | 8 | ||||
-rw-r--r-- | kexi/kexidb/field.cpp | 6 |
7 files changed, 21 insertions, 21 deletions
diff --git a/kexi/kexidb/driver.cpp b/kexi/kexidb/driver.cpp index 953243e4f..73b4f29cb 100644 --- a/kexi/kexidb/driver.cpp +++ b/kexi/kexidb/driver.cpp @@ -275,9 +275,9 @@ TQString Driver::valueToSQL( uint ftype, const TQVariant& v ) const case Field::Boolean: return TQString::number(v.toInt()?1:0); //0 or 1 case Field::Time: - return TQString("\'")+v.toTime().toString(Qt::ISODate)+"\'"; + return TQString("\'")+v.toTime().toString(TQt::ISODate)+"\'"; case Field::Date: - return TQString("\'")+v.toDate().toString(Qt::ISODate)+"\'"; + return TQString("\'")+v.toDate().toString(TQt::ISODate)+"\'"; case Field::DateTime: return dateTimeToSQL( v.toDateTime() ); case Field::BLOB: { diff --git a/kexi/kexidb/driver.h b/kexi/kexidb/driver.h index 3fc1acbf3..4abe86996 100644 --- a/kexi/kexidb/driver.h +++ b/kexi/kexidb/driver.h @@ -243,8 +243,8 @@ class KEXI_DB_EXPORT Driver : public TQObject, public KexiDB::Object @todo add support for time zones? */ //old const TQDateTime dt( v.toDateTime() ); -//old return TQString("\'")+dt.date().toString(Qt::ISODate)+" "+dt.time().toString(Qt::ISODate)+"\'"; - return TQString("\'")+v.toString(Qt::ISODate)+"\'"; +//old return TQString("\'")+dt.date().toString(TQt::ISODate)+" "+dt.time().toString(TQt::ISODate)+"\'"; + return TQString("\'")+v.toString(TQt::ISODate)+"\'"; } /*! Driver-specific SQL string escaping. diff --git a/kexi/kexidb/drivers/mySQL/mysqlpreparedstatement.cpp b/kexi/kexidb/drivers/mySQL/mysqlpreparedstatement.cpp index 74479fe77..6f9195859 100644 --- a/kexi/kexidb/drivers/mySQL/mysqlpreparedstatement.cpp +++ b/kexi/kexidb/drivers/mySQL/mysqlpreparedstatement.cpp @@ -229,7 +229,7 @@ m_stringBuffer[ 1024 ]; ??? break; case KexiDB::Field::Time: res = sqlite3_bind_text(prepared_st_handle, arg, - (*it).toTime().toString(Qt::ISODate).latin1(), + (*it).toTime().toString(TQt::ISODate).latin1(), sizeof("HH:MM:SS"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? @@ -238,7 +238,7 @@ m_stringBuffer[ 1024 ]; ??? break; case KexiDB::Field::Date: res = sqlite3_bind_text(prepared_st_handle, arg, - (*it).toDate().toString(Qt::ISODate).latin1(), + (*it).toDate().toString(TQt::ISODate).latin1(), sizeof("YYYY-MM-DD"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? @@ -247,7 +247,7 @@ m_stringBuffer[ 1024 ]; ??? break; case KexiDB::Field::DateTime: res = sqlite3_bind_text(prepared_st_handle, arg, - (*it).toDateTime().toString(Qt::ISODate).latin1(), + (*it).toDateTime().toString(TQt::ISODate).latin1(), sizeof("YYYY-MM-DDTHH:MM:SS"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? diff --git a/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp b/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp index 6a80f76de..902e729a5 100644 --- a/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp +++ b/kexi/kexidb/drivers/sqlite/sqlitecursor.cpp @@ -141,14 +141,14 @@ class KexiDB::SQLiteCursorData : public SQLiteConnectionInternal else { switch (f->type()) { case Field::Date: - return TQDate::fromString( GET_sqlite3_column_text, Qt::ISODate ); + return TQDate::fromString( GET_sqlite3_column_text, TQt::ISODate ); case Field::Time: //TQDateTime - a hack needed because TQVariant(TQTime) has broken isNull() return KexiUtils::stringToHackedTQTime(GET_sqlite3_column_text); case Field::DateTime: { TQString tmp( GET_sqlite3_column_text ); tmp[10] = 'T'; //for ISODate compatibility - return TQDateTime::fromString( tmp, Qt::ISODate ); + return TQDateTime::fromString( tmp, TQt::ISODate ); } case Field::Boolean: return TQVariant(sqliteStringToBool(GET_sqlite3_column_text)); @@ -483,7 +483,7 @@ void SQLiteCursor::storeCurrentRow(RowData &data) const data[i] = TQVariant( sqliteStringToBool(TQString::fromLatin1(*col)) ); break; case Field::Date: - data[i] = TQDate::fromString( TQString::fromLatin1(*col), Qt::ISODate ); + data[i] = TQDate::fromString( TQString::fromLatin1(*col), TQt::ISODate ); break; case Field::Time: //TQDateTime - a hack needed because TQVariant(TQTime) has broken isNull() @@ -492,7 +492,7 @@ void SQLiteCursor::storeCurrentRow(RowData &data) const case Field::DateTime: { TQString tmp( TQString::fromLatin1(*col) ); tmp[10] = 'T'; - data[i] = TQDateTime::fromString( tmp, Qt::ISODate ); + data[i] = TQDateTime::fromString( tmp, TQt::ISODate ); break; } default: diff --git a/kexi/kexidb/drivers/sqlite/sqlitepreparedstatement.cpp b/kexi/kexidb/drivers/sqlite/sqlitepreparedstatement.cpp index bccfd11b5..7a811d559 100644 --- a/kexi/kexidb/drivers/sqlite/sqlitepreparedstatement.cpp +++ b/kexi/kexidb/drivers/sqlite/sqlitepreparedstatement.cpp @@ -178,7 +178,7 @@ bool SQLitePreparedStatement::execute() break; case KexiDB::Field::Time: res = sqlite3_bind_text(prepared_st_handle, arg, - TQString((*it).toTime().toString(Qt::ISODate)).latin1(), + TQString((*it).toTime().toString(TQt::ISODate)).latin1(), sizeof("HH:MM:SS"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? @@ -187,7 +187,7 @@ bool SQLitePreparedStatement::execute() break; case KexiDB::Field::Date: res = sqlite3_bind_text(prepared_st_handle, arg, - TQString((*it).toDate().toString(Qt::ISODate)).latin1(), + TQString((*it).toDate().toString(TQt::ISODate)).latin1(), sizeof("YYYY-MM-DD"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? @@ -196,7 +196,7 @@ bool SQLitePreparedStatement::execute() break; case KexiDB::Field::DateTime: res = sqlite3_bind_text(prepared_st_handle, arg, - (*it).toDateTime().toString(Qt::ISODate).latin1(), + (*it).toDateTime().toString(TQt::ISODate).latin1(), sizeof("YYYY-MM-DDTHH:MM:SS"), SQLITE_TRANSIENT /*??*/); if (SQLITE_OK != res) { //! @todo msg? diff --git a/kexi/kexidb/expression.cpp b/kexi/kexidb/expression.cpp index f4e5ccfe8..25af20ee9 100644 --- a/kexi/kexidb/expression.cpp +++ b/kexi/kexidb/expression.cpp @@ -539,12 +539,12 @@ TQString ConstExpr::toString(QuerySchemaParameterValueListIterator* params) else if (m_token==REAL_CONST) return TQString::number(value.toPoint().x())+"."+TQString::number(value.toPoint().y()); else if (m_token==DATE_CONST) - return "'" + value.toDate().toString(Qt::ISODate) + "'"; + return "'" + value.toDate().toString(TQt::ISODate) + "'"; else if (m_token==DATETIME_CONST) - return "'" + value.toDateTime().date().toString(Qt::ISODate) - + " " + value.toDateTime().time().toString(Qt::ISODate) + "'"; + return "'" + value.toDateTime().date().toString(TQt::ISODate) + + " " + value.toDateTime().time().toString(TQt::ISODate) + "'"; else if (m_token==TIME_CONST) - return "'" + value.toTime().toString(Qt::ISODate) + "'"; + return "'" + value.toTime().toString(TQt::ISODate) + "'"; return value.toString(); } diff --git a/kexi/kexidb/field.cpp b/kexi/kexidb/field.cpp index 41cce80be..e2dd698e8 100644 --- a/kexi/kexidb/field.cpp +++ b/kexi/kexidb/field.cpp @@ -452,21 +452,21 @@ Field::setDefaultValue(const TQCString& def) m_defaultValue = TQVariant((bool)v); break; }case Date: {//YYYY-MM-DD - TQDate date = TQDate::fromString( def, Qt::ISODate ); + TQDate date = TQDate::fromString( def, TQt::ISODate ); if (!date.isValid()) m_defaultValue = TQVariant(); else m_defaultValue = TQVariant(date); break; }case DateTime: {//YYYY-MM-DDTHH:MM:SS - TQDateTime dt = TQDateTime::fromString( def, Qt::ISODate ); + TQDateTime dt = TQDateTime::fromString( def, TQt::ISODate ); if (!dt.isValid()) m_defaultValue = TQVariant(); else m_defaultValue = TQVariant(dt); break; }case Time: {//HH:MM:SS - TQTime time = TQTime::fromString( def, Qt::ISODate ); + TQTime time = TQTime::fromString( def, TQt::ISODate ); if (!time.isValid()) m_defaultValue = TQVariant(); else |