diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
commit | d6f8bbb45b267065a6907e71ff9c98bb6d161241 (patch) | |
tree | d109539636691d7b03036ca1c0ed29dbae6577cf /kdevdesigner/uilib/database.cpp | |
parent | 3331a47a9cad24795c7440ee8107143ce444ef34 (diff) | |
download | tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.tar.gz tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1157658 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdevdesigner/uilib/database.cpp')
-rw-r--r-- | kdevdesigner/uilib/database.cpp | 46 |
1 files changed, 23 insertions, 23 deletions
diff --git a/kdevdesigner/uilib/database.cpp b/kdevdesigner/uilib/database.cpp index a92a04c8..c9621604 100644 --- a/kdevdesigner/uilib/database.cpp +++ b/kdevdesigner/uilib/database.cpp @@ -37,10 +37,10 @@ #include "mainwindow.h" #endif -#include <qsqldatabase.h> -#include <qsqlform.h> -#include <qsqlcursor.h> -#include <qsqlrecord.h> +#include <tqsqldatabase.h> +#include <tqsqlform.h> +#include <tqsqlcursor.h> +#include <tqsqlrecord.h> DatabaseSupport::DatabaseSupport() { @@ -49,40 +49,40 @@ DatabaseSupport::DatabaseSupport() parent = 0; } -void DatabaseSupport::initPreview( const QString &connection, const QString &table, QObject *o, - const QMap<QString, QString> &databaseControls ) +void DatabaseSupport::initPreview( const TQString &connection, const TQString &table, TQObject *o, + const TQMap<TQString, TQString> &databaseControls ) { tbl = table; dbControls = databaseControls; parent = o; if ( connection != "(default)" ) - con = QSqlDatabase::database( connection ); + con = TQSqlDatabase::database( connection ); else - con = QSqlDatabase::database(); - frm = new QSqlForm( o, table ); - for ( QMap<QString, QString>::Iterator it = dbControls.begin(); it != dbControls.end(); ++it ) { - QObject *chld = parent->child( it.key(), "QWidget" ); + con = TQSqlDatabase::database(); + frm = new TQSqlForm( o, table ); + for ( TQMap<TQString, TQString>::Iterator it = dbControls.begin(); it != dbControls.end(); ++it ) { + TQObject *chld = parent->child( it.key(), "TQWidget" ); if ( !chld ) continue; - frm->insert( (QWidget*)chld, *it ); + frm->insert( (TQWidget*)chld, *it ); } } -QDesignerDataBrowser::QDesignerDataBrowser( QWidget *parent, const char *name ) - : QDataBrowser( parent, name ) +QDesignerDataBrowser::QDesignerDataBrowser( TQWidget *parent, const char *name ) + : TQDataBrowser( parent, name ) { } -bool QDesignerDataBrowser::event( QEvent* e ) +bool QDesignerDataBrowser::event( TQEvent* e ) { - bool b = QDataBrowser::event( e ); + bool b = TQDataBrowser::event( e ); #if defined(DESIGNER) if ( MainWindow::self->isPreviewing() ) { #endif - if ( e->type() == QEvent::Show ) { + if ( e->type() == TQEvent::Show ) { if ( con ) { - QSqlCursor* cursor = new QSqlCursor( tbl, TRUE, con ); + TQSqlCursor* cursor = new TQSqlCursor( tbl, TRUE, con ); setSqlCursor( cursor, TRUE ); setForm( frm ); refresh(); @@ -96,18 +96,18 @@ bool QDesignerDataBrowser::event( QEvent* e ) return b; } -QDesignerDataView::QDesignerDataView( QWidget *parent, const char *name ) - : QDataView( parent, name ) +QDesignerDataView::QDesignerDataView( TQWidget *parent, const char *name ) + : TQDataView( parent, name ) { } -bool QDesignerDataView::event( QEvent* e ) +bool QDesignerDataView::event( TQEvent* e ) { - bool b = QDataView::event( e ); + bool b = TQDataView::event( e ); #if defined(DESIGNER) if ( MainWindow::self->isPreviewing() ) { #endif - if ( e->type() == QEvent::Show ) { + if ( e->type() == TQEvent::Show ) { setForm( frm ); readFields(); return TRUE; |