summaryrefslogtreecommitdiffstats
path: root/languages/sql/sqlconfigwidget.ui.h
diff options
context:
space:
mode:
Diffstat (limited to 'languages/sql/sqlconfigwidget.ui.h')
-rw-r--r--languages/sql/sqlconfigwidget.ui.h82
1 files changed, 41 insertions, 41 deletions
diff --git a/languages/sql/sqlconfigwidget.ui.h b/languages/sql/sqlconfigwidget.ui.h
index c99d8722..26a9fb0b 100644
--- a/languages/sql/sqlconfigwidget.ui.h
+++ b/languages/sql/sqlconfigwidget.ui.h
@@ -7,11 +7,11 @@
** place of a destructor.
*****************************************************************************/
-#include <qsqldatabase.h>
-#include <qcombobox.h>
-#include <qspinbox.h>
-#include <qdom.h>
-#include <qstringlist.h>
+#include <tqsqldatabase.h>
+#include <tqcombobox.h>
+#include <tqspinbox.h>
+#include <tqdom.h>
+#include <tqstringlist.h>
#include <klocale.h>
#include <klineedit.h>
@@ -25,23 +25,23 @@
class PluginTableItem: public QTableItem
{
public:
- PluginTableItem( QTable* table, const QString& text = QString::null ): QTableItem( table, QTableItem::OnTyping, text ) {}
+ PluginTableItem( TQTable* table, const TQString& text = TQString::null ): TQTableItem( table, TQTableItem::OnTyping, text ) {}
- virtual QWidget* createEditor() const
+ virtual TQWidget* createEditor() const
{
- QComboBox* combo = new QComboBox( true, table() );
- combo->insertStringList( QSqlDatabase::drivers() );
+ TQComboBox* combo = new TQComboBox( true, table() );
+ combo->insertStringList( TQSqlDatabase::drivers() );
if ( !text().isEmpty() )
combo->setCurrentText( text() );
return combo;
}
- virtual void setContentFromEditor( QWidget* w )
+ virtual void setContentFromEditor( TQWidget* w )
{
- if ( w->inherits( "QComboBox" ) )
- setText( ( (QComboBox*)w )->currentText() );
+ if ( w->inherits( "TQComboBox" ) )
+ setText( ( (TQComboBox*)w )->currentText() );
else
- QTableItem::setContentFromEditor( w );
+ TQTableItem::setContentFromEditor( w );
}
};
@@ -49,23 +49,23 @@ public:
class PortTableItem: public QTableItem
{
public:
- PortTableItem( QTable* table, const QString& text = QString::null ): QTableItem( table, QTableItem::OnTyping, text ) {}
+ PortTableItem( TQTable* table, const TQString& text = TQString::null ): TQTableItem( table, TQTableItem::OnTyping, text ) {}
- virtual QWidget* createEditor() const
+ virtual TQWidget* createEditor() const
{
- QSpinBox* sb = new QSpinBox( -1, 65535, 1, table() );
+ TQSpinBox* sb = new TQSpinBox( -1, 65535, 1, table() );
sb->setSpecialValueText( i18n("Default") );
if ( !text().isEmpty() )
sb->setValue( text().toInt() );
return sb;
}
- virtual void setContentFromEditor( QWidget* w )
+ virtual void setContentFromEditor( TQWidget* w )
{
- if ( w->inherits( "QSpinBox" ) )
- setText( ( (QSpinBox*)w )->text() );
+ if ( w->inherits( "TQSpinBox" ) )
+ setText( ( (TQSpinBox*)w )->text() );
else
- QTableItem::setContentFromEditor( w );
+ TQTableItem::setContentFromEditor( w );
}
};
@@ -73,33 +73,33 @@ public:
class PasswordTableItem: public QTableItem
{
public:
- PasswordTableItem( QTable* table, const QString& text = QString::null ): QTableItem( table, QTableItem::OnTyping, text ) {}
+ PasswordTableItem( TQTable* table, const TQString& text = TQString::null ): TQTableItem( table, TQTableItem::OnTyping, text ) {}
- virtual QWidget* createEditor() const
+ virtual TQWidget* createEditor() const
{
KLineEdit* le = new KLineEdit( table() );
- le->setEchoMode( QLineEdit::Password );
+ le->setEchoMode( TQLineEdit::Password );
return le;
}
- virtual void setContentFromEditor( QWidget* w )
+ virtual void setContentFromEditor( TQWidget* w )
{
if ( w->inherits( "KLineEdit" ) ) {
password = ( (KLineEdit*)w )->text();
- setText( QString().fill( '*', password.length() ) );
+ setText( TQString().fill( '*', password.length() ) );
} else {
- QTableItem::setContentFromEditor( w );
+ TQTableItem::setContentFromEditor( w );
}
}
- virtual void setText(const QString& bogus)
+ virtual void setText(const TQString& bogus)
{
- QTableItem::setText(QString().fill('*', bogus.length()));
+ TQTableItem::setText(TQString().fill('*', bogus.length()));
}
- QString password;
+ TQString password;
};
-static bool isEmptyRow( QTable* tbl, int row )
+static bool isEmptyRow( TQTable* tbl, int row )
{
for ( int i = 0; i < tbl->numCols(); i++ ) {
if ( !tbl->text( row, i ).isEmpty() )
@@ -119,7 +119,7 @@ void SqlConfigWidget::init()
changed = false;
}
-static void addRow( QTable* dbTable )
+static void addRow( TQTable* dbTable )
{
dbTable->insertRows( dbTable->numRows() );
dbTable->setItem( dbTable->numRows() - 1, 0,
@@ -163,19 +163,19 @@ void SqlConfigWidget::updateButtons()
void SqlConfigWidget::testDb()
{
- static const QString cName( "SqlConfigWidgetTest" );
+ static const TQString cName( "SqlConfigWidgetTest" );
int cr = dbTable->currentRow();
if (cr < 0)
return;
- QSqlDatabase* db = QSqlDatabase::addDatabase( dbTable->text( cr, 0 ), cName );
+ TQSqlDatabase* db = TQSqlDatabase::addDatabase( dbTable->text( cr, 0 ), cName );
db->setDatabaseName( dbTable->text( cr, 1 ) );
db->setHostName( dbTable->text( cr, 2 ) );
bool ok;
int port = dbTable->text( cr, 3 ).toInt( &ok );
if (ok && port >= 0)
db->setPort( port );
- QString pass = ((PasswordTableItem*)dbTable->item( cr, 5 ))->password;
+ TQString pass = ((PasswordTableItem*)dbTable->item( cr, 5 ))->password;
if ( db->open( dbTable->text( cr, 4 ), pass ) ) {
KMessageBox::information( this, i18n("Connection successful") );
@@ -187,7 +187,7 @@ void SqlConfigWidget::testDb()
}
db = 0;
- QSqlDatabase::removeDatabase( cName );
+ TQSqlDatabase::removeDatabase( cName );
}
@@ -195,18 +195,18 @@ void SqlConfigWidget::accept()
{
Q_ASSERT( doc );
- QDomElement dbElem = DomUtil::createElementByPath( *doc, "/kdevsqlsupport/servers" );
+ TQDomElement dbElem = DomUtil::createElementByPath( *doc, "/kdevsqlsupport/servers" );
DomUtil::makeEmpty( dbElem );
for ( int i = 0; i < dbTable->numRows() - 1; i++ ) {
- QStringList db;
+ TQStringList db;
db << dbTable->text( i, 0 ) << dbTable->text( i, 1 )
<< dbTable->text( i, 2 ) << dbTable->text( i, 3 )
<< dbTable->text( i, 4 )
<< SQLSupportPart::cryptStr( ((PasswordTableItem*)dbTable->item( i, 5 ))->password );
DomUtil::writeListEntry( *doc,
- "/kdevsqlsupport/servers/server" + QString::number( i ),
+ "/kdevsqlsupport/servers/server" + TQString::number( i ),
"el", db );
}
if ( changed )
@@ -214,7 +214,7 @@ void SqlConfigWidget::accept()
}
-void SqlConfigWidget::setProjectDom( QDomDocument * doc )
+void SqlConfigWidget::setProjectDom( TQDomDocument * doc )
{
this->doc = doc;
}
@@ -224,10 +224,10 @@ void SqlConfigWidget::loadConfig()
{
Q_ASSERT( doc );
- QStringList db;
+ TQStringList db;
int i = 0;
while ( true ) {
- QStringList db = DomUtil::readListEntry( *doc, "kdevsqlsupport/servers/server" + QString::number( i ), "el" );
+ TQStringList db = DomUtil::readListEntry( *doc, "kdevsqlsupport/servers/server" + TQString::number( i ), "el" );
if ( db.isEmpty() )
return;