summaryrefslogtreecommitdiffstats
path: root/kexi/plugins/tables/kexitabledesignerview.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:32:11 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-15 15:32:11 -0600
commit94844816550ad672ccfcdc25659c625546239998 (patch)
treee35fc60fd736c645d59f6408af032774ad8023d3 /kexi/plugins/tables/kexitabledesignerview.cpp
parent2a811c38c74c03648ecf857e566c44483cbad706 (diff)
downloadkoffice-94844816550ad672ccfcdc25659c625546239998.tar.gz
koffice-94844816550ad672ccfcdc25659c625546239998.zip
Rename a number of old tq methods that are no longer tq specific
Diffstat (limited to 'kexi/plugins/tables/kexitabledesignerview.cpp')
-rw-r--r--kexi/plugins/tables/kexitabledesignerview.cpp58
1 files changed, 29 insertions, 29 deletions
diff --git a/kexi/plugins/tables/kexitabledesignerview.cpp b/kexi/plugins/tables/kexitabledesignerview.cpp
index 84ea686c..0563cde3 100644
--- a/kexi/plugins/tables/kexitabledesignerview.cpp
+++ b/kexi/plugins/tables/kexitabledesignerview.cpp
@@ -22,7 +22,7 @@
#include "kexilookupcolumnpage.h"
#include "kexitabledesignercommands.h"
-#include <tqlayout.h>
+#include <layout.h>
#include <tqlabel.h>
#include <tqsplitter.h>
@@ -168,7 +168,7 @@ KexiTableDesignerView::KexiTableDesignerView(KexiMainWindow *win, TQWidget *pare
connect(d->data, TQT_SIGNAL(aboutToDeleteRow(KexiTableItem&,KexiDB::ResultInfo*,bool)),
TQT_TQOBJECT(this), TQT_SLOT(slotAboutToDeleteRow(KexiTableItem&,KexiDB::ResultInfo*,bool)));
- setMinimumSize(d->view->tqminimumSizeHint().width(), d->view->tqminimumSizeHint().height());
+ setMinimumSize(d->view->minimumSizeHint().width(), d->view->minimumSizeHint().height());
d->view->setFocus();
d->sets = new KexiDataAwarePropertySet( this, d->view );
@@ -495,11 +495,11 @@ void KexiTableDesignerView::slotTogglePrimaryKey()
/* CommandGroup *setPrimaryKeyCommand;
if (isSet) {
setPrimaryKeyCommand = new CommandGroup(i18n("Set primary key for field \"%1\"")
- .tqarg(set["name"].value().toString()) );
+ .arg(set["name"].value().toString()) );
}
else {
setPrimaryKeyCommand = new CommandGroup(i18n("Unset primary key for field \"%1\"")
- .tqarg(set["name"].value().toString()) );
+ .arg(set["name"].value().toString()) );
}
switchPrimaryKey(set, isSet, false, setPrimaryKeyCommand);*/
//addHistoryCommand( setPrimaryKeyCommand, false /* !execute */ );
@@ -687,8 +687,8 @@ void KexiTableDesignerView::slotBeforeCellChanged(
//remember this action containing 2 subactions
CommandGroup *changeCaptionAndNameCommand = new CommandGroup(
i18n("Change \"%1\" field's name to \"%2\" and caption from \"%3\" to \"%4\"")
- .tqarg(oldName).tqarg(propertySetForItem->property("name").value().toString())
- .tqarg(oldCaption).tqarg(newValue.toString() ));
+ .arg(oldName).arg(propertySetForItem->property("name").value().toString())
+ .arg(oldCaption).arg(newValue.toString() ));
changeCaptionAndNameCommand->addCommand( changeCaptionCommand );
// new ChangeFieldPropertyCommand( this, *propertySetForItem,
// "caption", oldCaption, newValue)
@@ -759,7 +759,7 @@ void KexiTableDesignerView::slotBeforeCellChanged(
// *** this action contains subactions ***
CommandGroup *changeDataTypeCommand = new CommandGroup(
i18n("Change data type for field \"%1\" to \"%2\"")
- .tqarg(set["name"].value().toString()).tqarg( KexiDB::Field::typeName( fieldType ) ) );
+ .arg(set["name"].value().toString()).arg( KexiDB::Field::typeName( fieldType ) ) );
//kexipluginsdbg << "++++++++++" << slist << nlist << endl;
@@ -968,13 +968,13 @@ void KexiTableDesignerView::slotPropertyChanged(KoProperty::Set& set, KoProperty
//switchPrimaryKey(set, true);
// this will be toplevel command
setAutonumberCommand = new CommandGroup(
- i18n("Assign autonumber for field \"%1\"").tqarg(set["name"].value().toString()) );
+ i18n("Assign autonumber for field \"%1\"").arg(set["name"].value().toString()) );
toplevelCommand = setAutonumberCommand;
d->setPropertyValueIfNeeded( set, "autoIncrement", TQVariant(true,1), setAutonumberCommand );
}
else {
setAutonumberCommand = new CommandGroup(
- i18n("Remove autonumber from field \"%1\"").tqarg(set["name"].value().toString()) );
+ i18n("Remove autonumber from field \"%1\"").arg(set["name"].value().toString()) );
//d->slotPropertyChanged_enabled = false;
// set["autoIncrement"].setValue( TQVariant(false,1), false/*don't save old*/);
// d->slotPropertyChanged_enabled = true;
@@ -995,7 +995,7 @@ void KexiTableDesignerView::slotPropertyChanged(KoProperty::Set& set, KoProperty
setPrimaryKey = false;
// this will be toplevel command
CommandGroup *unsetIndexedOrUniquOrNotNullCommand = new CommandGroup(
- i18n("Set \"%1\" property for field \"%2\"").tqarg(property.caption()).tqarg(set["name"].value().toString()) );
+ i18n("Set \"%1\" property for field \"%2\"").arg(property.caption()).arg(set["name"].value().toString()) );
toplevelCommand = unsetIndexedOrUniquOrNotNullCommand;
d->setPropertyValueIfNeeded( set, pname, TQVariant(false,1), unsetIndexedOrUniquOrNotNullCommand );
if (pname=="notNull") {
@@ -1040,8 +1040,8 @@ void KexiTableDesignerView::slotPropertyChanged(KoProperty::Set& set, KoProperty
// kdDebug() << set["type"].value() << endl;
// if (KexiDB::Field::typeGroup( set["type"].value().toInt() ) == (int)KexiDB::Field::TextGroup) {
CommandGroup* changeFieldTypeCommand = new CommandGroup(
- i18n("Change type for field \"%1\" to \"%2\"").tqarg(set["name"].value().toString())
- .tqarg(typeName) );
+ i18n("Change type for field \"%1\" to \"%2\"").arg(set["name"].value().toString())
+ .arg(typeName) );
d->setPropertyValueIfNeeded( set, "subType", property.value(), property.oldValue(),
changeFieldTypeCommand );
@@ -1085,7 +1085,7 @@ void KexiTableDesignerView::slotPropertyChanged(KoProperty::Set& set, KoProperty
//this action contains subactions
CommandGroup *setPrimaryKeyCommand = new CommandGroup(
i18n("Set primary key for field \"%1\"")
- .tqarg(set["name"].value().toString()) );
+ .arg(set["name"].value().toString()) );
if (toplevelCommand)
toplevelCommand->addCommand( setPrimaryKeyCommand );
else
@@ -1111,7 +1111,7 @@ void KexiTableDesignerView::slotPropertyChanged(KoProperty::Set& set, KoProperty
//remember this action containing 2 subactions
CommandGroup *setPrimaryKeyCommand = new CommandGroup(
i18n("Unset primary key for field \"%1\"")
- .tqarg(set["name"].value().toString()) );
+ .arg(set["name"].value().toString()) );
if (toplevelCommand)
toplevelCommand->addCommand( setPrimaryKeyCommand );
else
@@ -1147,10 +1147,10 @@ void KexiTableDesignerView::slotRowInserted()
}
void KexiTableDesignerView::slotAboutToDeleteRow(
- KexiTableItem& item, KexiDB::ResultInfo* result, bool tqrepaint)
+ KexiTableItem& item, KexiDB::ResultInfo* result, bool repaint)
{
Q_UNUSED(result)
- Q_UNUSED(tqrepaint)
+ Q_UNUSED(repaint)
if (item[COLUMN_ID_ICON].toString()=="key")
d->primaryKeyExists = false;
@@ -1213,7 +1213,7 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
"for creating relations between database tables. "
"Do you want to add primary key automatically now?</p>"
"<p>If you want to add a primary key by hand, press \"Cancel\" "
- "to cancel saving table design.</p>").tqarg(schema.name()),
+ "to cancel saving table design.</p>").arg(schema.name()),
TQString(), KGuiItem(i18n("&Add Primary Key"), "key"), KStdGuiItem::no(),
"autogeneratePrimaryKeysOnTableDesignSaving");
if (questionRes==KMessageBox::Cancel) {
@@ -1229,9 +1229,9 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
KoProperty::Set *set = d->sets->at(i);
if (set) {
if ((*set)["name"].value().toString()
- == pkFieldName.tqarg(idIndex==1?TQString() : TQString::number(idIndex))
+ == pkFieldName.arg(idIndex==1?TQString() : TQString::number(idIndex))
|| (*set)["caption"].value().toString()
- == pkFieldCaption.tqarg(idIndex==1?TQString() : TQString::number(idIndex)))
+ == pkFieldCaption.arg(idIndex==1?TQString() : TQString::number(idIndex)))
{
//try next id index
i = 0;
@@ -1241,8 +1241,8 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
}
i++;
}
- pkFieldName = pkFieldName.tqarg(idIndex==1?TQString() : TQString::number(idIndex));
- pkFieldCaption = pkFieldCaption.tqarg(idIndex==1?TQString() : TQString::number(idIndex));
+ pkFieldName = pkFieldName.arg(idIndex==1?TQString() : TQString::number(idIndex));
+ pkFieldCaption = pkFieldCaption.arg(idIndex==1?TQString() : TQString::number(idIndex));
//ok, add PK with such unique name
d->view->insertEmptyRow(0);
d->view->setCursorPosition(0, COLUMN_ID_CAPTION);
@@ -1273,7 +1273,7 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
if (beSilent) {
kexipluginswarn <<
TQString("KexiTableDesignerView::buildSchema(): no field caption entered at row %1...")
- .tqarg(i+1) << endl;
+ .arg(i+1) << endl;
}
else {
d->view->setCursorPosition(i, COLUMN_ID_CAPTION);
@@ -1304,7 +1304,7 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
if (beSilent) {
kexipluginswarn <<
TQString("KexiTableDesignerView::buildSchema(): duplicated field name '%1'")
- .tqarg((*b)["name"].value().toString()) << endl;
+ .arg((*b)["name"].value().toString()) << endl;
}
else {
d->view->setCursorPosition(i, COLUMN_ID_CAPTION);
@@ -1313,7 +1313,7 @@ tristate KexiTableDesignerView::buildSchema(KexiDB::TableSchema &schema, bool be
KMessageBox::sorry(this,
i18n("You have added \"%1\" field name twice.\nField names cannot be repeated. "
"Correct name of the field.")
- .tqarg((*b)["name"].value().toString()) );
+ .arg((*b)["name"].value().toString()) );
}
res = cancelled;
}
@@ -1406,7 +1406,7 @@ KexiDB::SchemaData* KexiTableDesignerView::storeNewData(const KexiDB::SchemaData
KexiDB::Connection *conn = mainWin()->project()->dbConnection();
res = conn->createTable(tempData()->table);
if (res!=true)
- parentDialog()->settqStatus(conn, "");
+ parentDialog()->setStatus(conn, "");
}
if (res == true) {
@@ -1457,7 +1457,7 @@ tristate KexiTableDesignerView::storeData(bool dontAsk)
this, *conn, *tempData()->table,
i18n("You are about to change the design of table \"%1\" "
"but following objects using this table are opened:")
- .tqarg(tempData()->table->name()));
+ .arg(tempData()->table->name()));
}
if (res == true) {
@@ -1489,7 +1489,7 @@ tristate KexiTableDesignerView::storeData(bool dontAsk)
res = conn->alterTable(*tempData()->table, *newTable);
if (res != true)
- parentDialog()->settqStatus(conn, "");
+ parentDialog()->setStatus(conn, "");
}
else {
KexiDB::AlterTableHandler::ExecutionArguments args;
@@ -1499,7 +1499,7 @@ tristate KexiTableDesignerView::storeData(bool dontAsk)
<< res.toString() << endl;
if (true != res) {
alterTableHandler->debugError();
- parentDialog()->settqStatus(alterTableHandler, "");
+ parentDialog()->setStatus(alterTableHandler, "");
}
}
}
@@ -1659,7 +1659,7 @@ void KexiTableDesignerView::slotAboutToShowContextMenu()
if (captionOrName.isEmpty())
captionOrName = set["name"].value().toString();
//! @todo show "field" icon
- d->contextMenuTitle->setTitle( i18n("Table field \"%1\"").tqarg(captionOrName) );
+ d->contextMenuTitle->setTitle( i18n("Table field \"%1\"").arg(captionOrName) );
}
else {
d->contextMenuTitle->setTitle( i18n("Empty table row", "Empty Row") );