diff options
Diffstat (limited to 'kexi/plugins')
37 files changed, 125 insertions, 125 deletions
diff --git a/kexi/plugins/forms/kexiactionselectiondialog.cpp b/kexi/plugins/forms/kexiactionselectiondialog.cpp index 31ab61d0..9318bb5e 100644 --- a/kexi/plugins/forms/kexiactionselectiondialog.cpp +++ b/kexi/plugins/forms/kexiactionselectiondialog.cpp @@ -142,7 +142,7 @@ void KActionsListViewBase::init() if (!isActionVisible((*it)->name(), actionCategories)) continue; ActionSelectorDialogListItem *pitem = new ActionSelectorDialogListItem((*it)->name(), - this, (*it)->toolTip().isEmpty() ? (*it)->text().tqreplace("&", "") : (*it)->toolTip() ); + this, (*it)->toolTip().isEmpty() ? (*it)->text().replace("&", "") : (*it)->toolTip() ); pitem->fifoSorting = false; //alpha sort pitem->setPixmap( 0, (*it)->iconSet( KIcon::Small, 16 ).pixmap( TQIconSet::Small, TQIconSet::Active ) ); if (!pitem->pixmap(0) || pitem->pixmap(0)->isNull()) @@ -278,7 +278,7 @@ class ActionToExecuteListView : public ActionsListViewBase printItem->setPixmap(0, SmallIcon("fileprint")); KAction *a = KStdAction::printPreview(0, 0, 0); item = new ActionSelectorDialogListItem("printPreview", printItem, - a->text().tqreplace("&", "").tqreplace("...", "")); + a->text().replace("&", "").replace("...", "")); item->setPixmap(0, SmallIcon(a->icon())); delete a; item = new ActionSelectorDialogListItem("pageSetup", printItem, i18n("Show Page Setup")); diff --git a/kexi/plugins/forms/kexidataprovider.cpp b/kexi/plugins/forms/kexidataprovider.cpp index 3e1e5c4b..7e5b9b85 100644 --- a/kexi/plugins/forms/kexidataprovider.cpp +++ b/kexi/plugins/forms/kexidataprovider.cpp @@ -81,7 +81,7 @@ void KexiFormDataProvider::setMainDataSourceWidget(TQWidget* mainWidget) kexipluginsdbg << obj->name() << endl; m_dataItems.append( formDataItem ); formDataItem->installListener( this ); - tmpSources.tqreplace( dataSource, (char*)1 ); + tmpSources.replace( dataSource, (char*)1 ); } delete l; //now we've got a set (unique list) of field names in tmpSources @@ -145,7 +145,7 @@ void KexiFormDataProvider::fillDuplicatedDataItems( if (!it.current()->columnInfo() || !it.current()->columnInfo()->field) continue; kdDebug() << " ** " << it.current()->columnInfo()->field->name() << endl; - it_dup = tmpDuplicatedItems.tqfind( it.current()->columnInfo()->field ); + it_dup = tmpDuplicatedItems.find( it.current()->columnInfo()->field ); uint count; if (it_dup==tmpDuplicatedItems.end()) count = 0; @@ -162,7 +162,7 @@ void KexiFormDataProvider::fillDuplicatedDataItems( } } } - if (item->columnInfo() && m_duplicatedItems->tqfind( item->columnInfo()->field )) { + if (item->columnInfo() && m_duplicatedItems->find( item->columnInfo()->field )) { for (TQPtrListIterator<KexiFormDataItemInterface> it(m_dataItems); it.current(); ++it) { if (it.current()!=item && item->columnInfo()->field == it.current()->columnInfo()->field) { kexipluginsdbg << "- setting a copy of value for item '" @@ -248,7 +248,7 @@ void KexiFormDataProvider::invalidateDataSources( const TQDict<char>& invalidSou const int newIndex = newIndices.at( it.data(), &ok ); if (ok && newIndex!=-1) { kexipluginsdbg << "invalidateDataSources(): " << it.key()->dataSource() << ": " << it.data() << " -> " << newIndex << endl; - newFieldNumbersForDataItems.tqreplace(it.key(), newIndex); + newFieldNumbersForDataItems.replace(it.key(), newIndex); } else { kexipluginsdbg << "invalidateDataSources(): removing " << it.key()->dataSource() << endl; @@ -304,7 +304,7 @@ void KexiFormDataProvider::invalidateDataSources( const TQDict<char>& invalidSou } } } - tmpUsedDataSources.tqreplace( item->dataSource().lower(), (char*)1 ); + tmpUsedDataSources.replace( item->dataSource().lower(), (char*)1 ); ++it; } m_disableFillDuplicatedDataItems = false; diff --git a/kexi/plugins/forms/kexidatasourcepage.cpp b/kexi/plugins/forms/kexidatasourcepage.cpp index ce11e7d9..74f9af05 100644 --- a/kexi/plugins/forms/kexidatasourcepage.cpp +++ b/kexi/plugins/forms/kexidatasourcepage.cpp @@ -357,26 +357,26 @@ void KexiDataSourcePage::setDataSource(const TQCString& mimeType, const TQCStrin void KexiDataSourcePage::assignPropertySet(KoProperty::Set* propertySet) { TQCString objectName; - if (propertySet && propertySet->tqcontains("name")) + if (propertySet && propertySet->contains("name")) objectName = (*propertySet)["name"].value().toCString(); if (!objectName.isEmpty() && objectName == m_currentObjectName) return; //the same object m_currentObjectName = objectName; TQCString objectClassName; - if (propertySet && propertySet->tqcontains("this:className")) + if (propertySet && propertySet->contains("this:className")) objectClassName = (*propertySet)["this:className"].value().toCString(); /*moved if (propertySet) { TQCString iconName; TQString objectClassString; - if (propertySet->tqcontains("this:iconName")) + if (propertySet->contains("this:iconName")) iconName = (*propertySet)["this:iconName"].value().toCString(); - if (propertySet->tqcontains("this:classString")) + if (propertySet->contains("this:classString")) objectClassString = (*propertySet)["this:classString"].value().toString(); m_objectInfoLabel->setObjectName(objectName); m_objectInfoLabel->setObjectClassIcon(iconName); m_objectInfoLabel->setObjectClassName(objectClassString); - if (propertySet->tqcontains("this:className")) + if (propertySet->contains("this:className")) objectClassName = (*propertySet)["this:className"].value().toCString(); }*/ KexiPropertyEditorView::updateInfoLabelForPropertySet( @@ -396,7 +396,7 @@ void KexiDataSourcePage::assignPropertySet(KoProperty::Set* propertySet) // else { const bool multipleSelection = objectClassName=="special:multiple"; - const bool hasDataSourceProperty = propertySet && propertySet->tqcontains("dataSource") && !multipleSelection; + const bool hasDataSourceProperty = propertySet && propertySet->contains("dataSource") && !multipleSelection; if (!isForm) { //this is a widget diff --git a/kexi/plugins/forms/kexiformeventhandler.cpp b/kexi/plugins/forms/kexiformeventhandler.cpp index de2d8570..cd6f5ac3 100644 --- a/kexi/plugins/forms/kexiformeventhandler.cpp +++ b/kexi/plugins/forms/kexiformeventhandler.cpp @@ -46,7 +46,7 @@ bool KexiFormEventAction::ActionData::isEmpty() const KexiPart::Info* KexiFormEventAction::ActionData::decodeString( TQString& actionType, TQString& actionArg, bool& ok) const { - const int idx = string.tqfind(':'); + const int idx = string.find(':'); ok = false; if (idx==-1) return 0; diff --git a/kexi/plugins/forms/kexiformmanager.cpp b/kexi/plugins/forms/kexiformmanager.cpp index ce9b142b..3c76e7d9 100644 --- a/kexi/plugins/forms/kexiformmanager.cpp +++ b/kexi/plugins/forms/kexiformmanager.cpp @@ -120,10 +120,10 @@ void KexiFormManager::setFormDataSource(const TQCString& mime, const TQCString& if (activeForm()->selectedWidget() == formWidget) { //active form is selected: just use properties system KFormDesigner::WidgetPropertySet *set = propertySet(); - if (!set || !set->tqcontains("dataSource")) + if (!set || !set->contains("dataSource")) return; (*set)["dataSource"].setValue(name); - if (set->tqcontains("dataSourceMimeType")) + if (set->contains("dataSourceMimeType")) (*set)["dataSourceMimeType"].setValue(mime); return; } @@ -159,19 +159,19 @@ void KexiFormManager::setDataSourceFieldOrExpression(const TQString& string, con // return; KFormDesigner::WidgetPropertySet *set = propertySet(); - if (!set || !set->tqcontains("dataSource")) + if (!set || !set->contains("dataSource")) return; (*set)["dataSource"].setValue(string); - if (set->tqcontains("autoCaption") && (*set)["autoCaption"].value().toBool()) { - if (set->tqcontains("fieldCaptionInternal")) + if (set->contains("autoCaption") && (*set)["autoCaption"].value().toBool()) { + if (set->contains("fieldCaptionInternal")) (*set)["fieldCaptionInternal"].setValue(caption); } if (//type!=KexiDB::Field::InvalidType && - set->tqcontains("widgetType") && (*set)["widgetType"].value().toString()=="Auto") + set->contains("widgetType") && (*set)["widgetType"].value().toString()=="Auto") { - if (set->tqcontains("fieldTypeInternal")) + if (set->contains("fieldTypeInternal")) (*set)["fieldTypeInternal"].setValue(type); } diff --git a/kexi/plugins/forms/kexiformpart.cpp b/kexi/plugins/forms/kexiformpart.cpp index 3f1d3466..e03a0779 100644 --- a/kexi/plugins/forms/kexiformpart.cpp +++ b/kexi/plugins/forms/kexiformpart.cpp @@ -466,7 +466,7 @@ KexiFormPart::slotPropertyChanged(TQWidget *w, const TQCString &name, const TQVa } if (KFormDesigner::FormManager::self()->activeForm()->widget() && name == "geometry") { //fall back to sizeInternal property.... - if (KFormDesigner::FormManager::self()->propertySet()->tqcontains("sizeInternal")) + if (KFormDesigner::FormManager::self()->propertySet()->contains("sizeInternal")) KFormDesigner::FormManager::self()->propertySet()->property("sizeInternal").setValue(TQSize(value.toRect().size())); } } diff --git a/kexi/plugins/forms/kexiformscrollview.cpp b/kexi/plugins/forms/kexiformscrollview.cpp index 057e0a33..5996061f 100644 --- a/kexi/plugins/forms/kexiformscrollview.cpp +++ b/kexi/plugins/forms/kexiformscrollview.cpp @@ -394,7 +394,7 @@ int KexiFormScrollView::columns() const KexiFormDataItemInterface *item = dynamic_cast<KexiFormDataItemInterface*>(dbFormWidget()->orderedDataAwareWidgets()->at( col )); if (!item) return -1; - KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.tqfind( item )); + KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.find( item )); return it!=m_fieldNumbersForDataItems.constEnd() ? it.data() : -1; }*/ @@ -421,7 +421,7 @@ bool KexiFormScrollView::columnEditable(int col) if (!item || item->isReadOnly()) return false; -// KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.tqfind( item )); +// KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.find( item )); // return KexiDataAwareObjectInterface::columnEditable( it!=m_fieldNumbersForDataItems.constEnd() ? it.data() : -1 ); return KexiDataAwareObjectInterface::columnEditable( col ); } diff --git a/kexi/plugins/forms/kexiformscrollview.h b/kexi/plugins/forms/kexiformscrollview.h index cf2731d1..61c13a8f 100644 --- a/kexi/plugins/forms/kexiformscrollview.h +++ b/kexi/plugins/forms/kexiformscrollview.h @@ -79,7 +79,7 @@ class KEXIFORMUTILS_EXPORT KexiFormScrollView : dbFormWidget()->orderedDataAwareWidgets()->at( col )); if (!item) return -1; - KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.tqfind( item )); + KexiFormDataItemInterfaceToIntMap::ConstIterator it(m_fieldNumbersForDataItems.find( item )); return it!=m_fieldNumbersForDataItems.constEnd() ? (int)it.data() : -1; } diff --git a/kexi/plugins/forms/kexiformview.cpp b/kexi/plugins/forms/kexiformview.cpp index 3f30fff2..3b12588c 100644 --- a/kexi/plugins/forms/kexiformview.cpp +++ b/kexi/plugins/forms/kexiformview.cpp @@ -345,7 +345,7 @@ void KexiFormView::updateValuesForSubproperties() kexipluginsdbg << "KexiFormView::loadForm(): delayed setting of the subproperty: widget=" << it.current()->widget()->name() << " prop=" << subpropIt.key() << " val=" << subpropIt.data() << endl; - const int count = subwidget->tqmetaObject()->tqfindProperty(subpropIt.key().latin1(), true); + const int count = subwidget->tqmetaObject()->findProperty(subpropIt.key().latin1(), true); const TQMetaProperty *meta = count!=-1 ? subwidget->tqmetaObject()->property(count, true) : 0; if (meta) { // Special case: the property value of type enum (set) but is saved as a string list, @@ -371,7 +371,7 @@ void KexiFormView::updateValuesForSubproperties() static void setUnsavedBLOBIdsForDataViewMode( TQWidget* widget, const TQMap<TQCString, KexiBLOBBuffer::Id_t>& unsavedLocalBLOBsByName) { - if (-1 != widget->tqmetaObject()->tqfindProperty("pixmapId")) { + if (-1 != widget->tqmetaObject()->findProperty("pixmapId")) { const KexiBLOBBuffer::Id_t blobID = unsavedLocalBLOBsByName[ widget->name() ]; if (blobID > 0) widget->setProperty("pixmapId", (uint /* KexiBLOBBuffer::Id_t is unsafe and unsupported by TQVariant - will be fixed in TQt4*/)blobID); @@ -783,7 +783,7 @@ KexiFormView::storeData(bool dontAsk) TQString originalFileName(h.originalFileName()); TQFileInfo fi(originalFileName); - TQString caption(fi.baseName().tqreplace('_', " ").simplifyWhiteSpace()); + TQString caption(fi.baseName().replace('_', " ").simplifyWhiteSpace()); if (st) { *st /* << NO, (pgsql doesn't support this):TQVariant()*/ /*id*/ @@ -1044,9 +1044,9 @@ KexiFormView::updateDataSourcePage() if (viewMode()==Kexi::DesignViewMode) { TQCString dataSourceMimeType, dataSource; KFormDesigner::WidgetPropertySet *set = KFormDesigner::FormManager::self()->propertySet(); - if (set->tqcontains("dataSourceMimeType")) + if (set->contains("dataSourceMimeType")) dataSourceMimeType = (*set)["dataSourceMimeType"].value().toCString(); - if (set->tqcontains("dataSource")) + if (set->contains("dataSource")) dataSource = (*set)["dataSource"].value().toCString(); formPart()->dataSourcePage()->setDataSource(dataSourceMimeType, dataSource); @@ -1149,7 +1149,7 @@ KexiFormView::insertAutoFields(const TQString& sourceMimeType, const TQString& s group->addCommand(insertCmd, false/*don't exec twice*/); KFormDesigner::ObjectTreeItem *newWidgetItem - = form()->objectTree()->dict()->tqfind(insertCmd->widgetName()); + = form()->objectTree()->dict()->find(insertCmd->widgetName()); KexiDBAutoField* newWidget = newWidgetItem ? dynamic_cast<KexiDBAutoField*>(newWidgetItem->widget()) : 0; widgetsToSelect.append(newWidget); diff --git a/kexi/plugins/forms/widgets/kexidbcombobox.cpp b/kexi/plugins/forms/widgets/kexidbcombobox.cpp index f977a962..f194908f 100644 --- a/kexi/plugins/forms/widgets/kexidbcombobox.cpp +++ b/kexi/plugins/forms/widgets/kexidbcombobox.cpp @@ -211,7 +211,7 @@ void KexiDBComboBox::createEditor() void KexiDBComboBox::setLabelPosition(LabelPosition position) { if(m_subwidget) { - if (-1 != m_subwidget->tqmetaObject()->tqfindProperty("frameShape", true)) + if (-1 != m_subwidget->tqmetaObject()->findProperty("frameShape", true)) m_subwidget->setProperty("frameShape", TQVariant((int)TQFrame::NoFrame)); m_subwidget->setGeometry( editorGeometry() ); } @@ -247,7 +247,7 @@ bool KexiDBComboBox::handleMousePressEvent(TQMouseEvent *e) return; }*/ - if ( /*count() &&*/ ( !isEditable() || buttonGeometry().tqcontains( e->pos() ) ) ) { + if ( /*count() &&*/ ( !isEditable() || buttonGeometry().contains( e->pos() ) ) ) { d->buttonPressed = false; /* if ( d->usingListBox() ) { @@ -256,7 +256,7 @@ bool KexiDBComboBox::handleMousePressEvent(TQMouseEvent *e) listBox()->setCurrentItem(d->current); listBox()->blockSignals( FALSE ); popup(); - if ( arrowRect.tqcontains( e->pos() ) ) { + if ( arrowRect.contains( e->pos() ) ) { d->arrowPressed = TRUE; d->arrowDown = TRUE; tqrepaint( FALSE ); @@ -339,7 +339,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e ) } else if (e->type()==TQEvent::Enter) { if (!d->isEditable - || /*over button if editable combo*/buttonGeometry().tqcontains( TQT_TQMOUSEEVENT(e)->pos() )) + || /*over button if editable combo*/buttonGeometry().contains( TQT_TQMOUSEEVENT(e)->pos() )) { d->mouseOver = true; update(); @@ -347,7 +347,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e ) } else if (e->type()==TQEvent::MouseMove) { if (d->isEditable) { - const bool overButton = buttonGeometry().tqcontains( TQT_TQMOUSEEVENT(e)->pos() ); + const bool overButton = buttonGeometry().contains( TQT_TQMOUSEEVENT(e)->pos() ); if (overButton != d->mouseOver) { d->mouseOver = overButton; update(); @@ -370,7 +370,7 @@ bool KexiDBComboBox::eventFilter( TQObject *o, TQEvent *e ) } } } - else if (!d->isEditable && d->subWidgetsWithDisabledEvents && d->subWidgetsWithDisabledEvents->tqfind(o)) { + else if (!d->isEditable && d->subWidgetsWithDisabledEvents && d->subWidgetsWithDisabledEvents->find(o)) { if (e->type()==TQEvent::MouseButtonPress) { // clicking the subwidget should mean the same as clicking the combo box (i.e. show the popup) if (handleMousePressEvent(TQT_TQMOUSEEVENT(e))) diff --git a/kexi/plugins/forms/widgets/kexidbform.cpp b/kexi/plugins/forms/widgets/kexidbform.cpp index cca955e5..c2a705c0 100644 --- a/kexi/plugins/forms/widgets/kexidbform.cpp +++ b/kexi/plugins/forms/widgets/kexidbform.cpp @@ -66,7 +66,7 @@ class KexiDBForm::Private int indexOfDataItem( KexiDataItemInterface* item ) const { TQMapConstIterator<KexiDataItemInterface*, uint> indicesForDataAwareWidgetsIt( - indicesForDataAwareWidgets.tqfind(item)); + indicesForDataAwareWidgets.find(item)); if (indicesForDataAwareWidgetsIt == indicesForDataAwareWidgets.constEnd()) return -1; kexipluginsdbg << "KexiDBForm: column # for item: " @@ -342,7 +342,7 @@ void KexiDBForm::updateTabStopsOrder(KFormDesigner::Form* form) // /*! @todo d->indicesForDataAwareWidgets SHOULDNT BE UPDATED HERE BECAUSE // THERE CAN BE ALSO NON-TABSTOP DATA WIDGETS! // */ - d->indicesForDataAwareWidgets.tqreplace( + d->indicesForDataAwareWidgets.replace( dataItem, numberOfDataAwareWidgets ); numberOfDataAwareWidgets++; diff --git a/kexi/plugins/forms/widgets/kexidblabel.cpp b/kexi/plugins/forms/widgets/kexidblabel.cpp index af539e3d..8226d3c4 100644 --- a/kexi/plugins/forms/widgets/kexidblabel.cpp +++ b/kexi/plugins/forms/widgets/kexidblabel.cpp @@ -482,7 +482,7 @@ void KexiDBLabel::paintEvent( TQPaintEvent* e ) the shadow has to be drawn using an offset relative to the widgets border. */ - if ( !d->pixmapDirty && e->rect().tqcontains( d->shadowPosition ) && !d->shadowPixmap.isNull()) { + if ( !d->pixmapDirty && e->rect().contains( d->shadowPosition ) && !d->shadowPixmap.isNull()) { TQRect clipRect = TQRect( TQMAX( e->rect().x() - d->shadowPosition.x(), 0 ), TQMAX( e->rect().y() - d->shadowPosition.y(), 0 ), diff --git a/kexi/plugins/forms/widgets/kexidbsubform.cpp b/kexi/plugins/forms/widgets/kexidbsubform.cpp index 6fcd851a..283631c3 100644 --- a/kexi/plugins/forms/widgets/kexidbsubform.cpp +++ b/kexi/plugins/forms/widgets/kexidbsubform.cpp @@ -79,7 +79,7 @@ KexiDBSubForm::setFormName(const TQString &name) TQStringList list; while(pw) { if(pw->isA("KexiDBSubForm")) { - if(list.tqcontains(pw->name())) { + if(list.contains(pw->name())) { //! @todo error message return; // Be sure to don't run into a endless-loop cause of recursive subforms. } diff --git a/kexi/plugins/importexport/csv/kexicsv_importexportpart.cpp b/kexi/plugins/importexport/csv/kexicsv_importexportpart.cpp index 4112bf52..7037b29a 100644 --- a/kexi/plugins/importexport/csv/kexicsv_importexportpart.cpp +++ b/kexi/plugins/importexport/csv/kexicsv_importexportpart.cpp @@ -76,7 +76,7 @@ bool KexiCSVImportExportPart::executeCommand(KexiMainWindow* mainWin, const char KexiDB::TableOrQuerySchema tableOrQuery( mainWin->project()->dbConnection(), options.itemId); TQTextStream *stream = 0; - if (args->tqcontains("textStream")) + if (args->contains("textStream")) stream = KexiUtils::stringToPtr<TQTextStream>( (*args)["textStream"] ); return KexiCSVExport::exportData(tableOrQuery, options, -1, stream); } diff --git a/kexi/plugins/importexport/csv/kexicsvexport.cpp b/kexi/plugins/importexport/csv/kexicsvexport.cpp index 5af3d8ed..f3347676 100644 --- a/kexi/plugins/importexport/csv/kexicsvexport.cpp +++ b/kexi/plugins/importexport/csv/kexicsvexport.cpp @@ -55,12 +55,12 @@ bool Options::assign( TQMap<TQString,TQString>& args ) mode = (args["destinationType"]=="file") ? KexiCSVExport::File : KexiCSVExport::Clipboard; - if (args.tqcontains("delimiter")) + if (args.contains("delimiter")) delimiter = args["delimiter"]; else delimiter = (mode==File) ? KEXICSV_DEFAULT_FILE_DELIMITER : KEXICSV_DEFAULT_CLIPBOARD_DELIMITER; - if (args.tqcontains("textQuote")) + if (args.contains("textQuote")) textQuote = args["textQuote"]; else textQuote = (mode==File) ? KEXICSV_DEFAULT_FILE_TEXT_TQUOTE : KEXICSV_DEFAULT_CLIPBOARD_TEXT_TQUOTE; @@ -69,9 +69,9 @@ bool Options::assign( TQMap<TQString,TQString>& args ) itemId = args["itemId"].toInt(&ok); if (!ok || itemId<=0) return false; - if (args.tqcontains("forceDelimiter")) + if (args.contains("forceDelimiter")) forceDelimiter = args["forceDelimiter"]; - if (args.tqcontains("addColumnNames")) + if (args.contains("addColumnNames")) addColumnNames = (args["addColumnNames"]=="1"); return true; } @@ -193,7 +193,7 @@ bool KexiCSVExport::exportData(KexiDB::TableOrQuerySchema& tableOrQuery, if (i>0) APPEND( delimiter ); if (hasTextQuote){ - APPEND( textQuote + fields[i]->captionOrAliasOrName().tqreplace(textQuote, escapedTextQuote) + textQuote ); + APPEND( textQuote + fields[i]->captionOrAliasOrName().replace(textQuote, escapedTextQuote) + textQuote ); } else { APPEND( fields[i]->captionOrAliasOrName() ); @@ -218,7 +218,7 @@ bool KexiCSVExport::exportData(KexiDB::TableOrQuerySchema& tableOrQuery, continue; if (isText[real_i]) { if (hasTextQuote) - APPEND( textQuote + TQString(cursor->value(real_i).toString()).tqreplace(textQuote, escapedTextQuote) + textQuote ); + APPEND( textQuote + TQString(cursor->value(real_i).toString()).replace(textQuote, escapedTextQuote) + textQuote ); else APPEND( cursor->value(real_i).toString() ); } diff --git a/kexi/plugins/importexport/csv/kexicsvexportwizard.cpp b/kexi/plugins/importexport/csv/kexicsvexportwizard.cpp index 931eab73..956681b1 100644 --- a/kexi/plugins/importexport/csv/kexicsvexportwizard.cpp +++ b/kexi/plugins/importexport/csv/kexicsvexportwizard.cpp @@ -378,9 +378,9 @@ static TQString convertKey(const char *key, KexiCSVExport::Mode mode) { TQString _key(TQString::tqfromLatin1(key)); if (mode == KexiCSVExport::Clipboard) { - _key.tqreplace("Exporting", "Copying"); - _key.tqreplace("Export", "Copy"); - _key.tqreplace("CSVFiles", "CSVToClipboard"); + _key.replace("Exporting", "Copying"); + _key.replace("Export", "Copy"); + _key.replace("CSVFiles", "CSVToClipboard"); } return _key; } diff --git a/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp b/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp index 3060db2a..01601230 100644 --- a/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp +++ b/kexi/plugins/importexport/csv/kexicsvimportdialog.cpp @@ -1104,7 +1104,7 @@ void KexiCSVImportDialog::setText(int row, int col, const TQString& text, bool i //! @todo what about time and float/double types and different integer subtypes? } else if (detectedType==_FP_NUMBER_TYPE) { - //tqreplace ',' with '.' + //replace ',' with '.' TQCString t(text.latin1()); const int textLen = t.length(); for (int i=0; i<textLen; i++) { @@ -1348,7 +1348,7 @@ void KexiCSVImportDialog::accept() suggestedName = KURL::fromPathOrURL(m_fname).fileName(); //remove extension if (!suggestedName.isEmpty()) { - const int idx = suggestedName.tqfindRev("."); + const int idx = suggestedName.findRev("."); if (idx!=-1) suggestedName = suggestedName.mid(0, idx ).simplifyWhiteSpace(); } @@ -1414,9 +1414,9 @@ void KexiCSVImportDialog::accept() for (uint col = 0; col < numCols; col++) colnames.append( m_table->text(0, col).lower().simplifyWhiteSpace() ); - if (colnames.tqfind(fieldName)!=colnames.end()) { + if (colnames.find(fieldName)!=colnames.end()) { int num = 1; - while (colnames.tqfind(fieldName+TQString::number(num))!=colnames.end()) + while (colnames.find(fieldName+TQString::number(num))!=colnames.end()) num++; fieldName += TQString::number(num); fieldCaption += TQString::number(num); diff --git a/kexi/plugins/macros/kexiactions/datatableaction.cpp b/kexi/plugins/macros/kexiactions/datatableaction.cpp index fff0eaf5..d2eb1df1 100644 --- a/kexi/plugins/macros/kexiactions/datatableaction.cpp +++ b/kexi/plugins/macros/kexiactions/datatableaction.cpp @@ -93,7 +93,7 @@ namespace KexiMacro { //this->appendChild( KSharedPtr<KoMacro::Variable>(new KoMacro::Variable(name)) ); } const TQString n = - namelist.tqcontains(partitem) + namelist.contains(partitem) ? partitem : namelist.count() > 0 ? namelist[0] : ""; this->setVariant(n); diff --git a/kexi/plugins/macros/kexiactions/objectnamevariable.h b/kexi/plugins/macros/kexiactions/objectnamevariable.h index e9ffa949..419e2b00 100644 --- a/kexi/plugins/macros/kexiactions/objectnamevariable.h +++ b/kexi/plugins/macros/kexiactions/objectnamevariable.h @@ -63,7 +63,7 @@ namespace KexiMacro { for(TQStringList::Iterator it = namelist.begin(); it != namelist.end(); ++it) this->appendChild( KSharedPtr<KoMacro::Variable>(new KoMacro::Variable(*it)) ); - this->setVariant( (name.isNull() || ! namelist.tqcontains(name)) ? namelist[0] : name ); + this->setVariant( (name.isNull() || ! namelist.contains(name)) ? namelist[0] : name ); kdDebug()<<"##################### KexiActions::ObjectNameVariable() objectname="<<objectname<<" name="<<name<<" value="<<this->variant()<<" tqchildren="<<namelist<<endl; } diff --git a/kexi/plugins/macros/kexiactions/openaction.cpp b/kexi/plugins/macros/kexiactions/openaction.cpp index 2e43116f..9cd2e664 100644 --- a/kexi/plugins/macros/kexiactions/openaction.cpp +++ b/kexi/plugins/macros/kexiactions/openaction.cpp @@ -66,7 +66,7 @@ namespace KexiMacro { this->tqchildren().append( KSharedPtr<KoMacro::Variable>(new KoMacro::Variable(*it)) ); } const TQString n = - namelist.tqcontains(viewname) + namelist.contains(viewname) ? viewname : namelist.count() > 0 ? namelist[0] : ""; diff --git a/kexi/plugins/macros/kexipart/keximacrodesignview.cpp b/kexi/plugins/macros/kexipart/keximacrodesignview.cpp index 4d480365..efce73c0 100644 --- a/kexi/plugins/macros/kexipart/keximacrodesignview.cpp +++ b/kexi/plugins/macros/kexipart/keximacrodesignview.cpp @@ -264,7 +264,7 @@ void KexiMacroDesignView::beforeCellChanged(KexiTableItem* item, int colnum, TQV Q_UNUSED(result); kdDebug() << "KexiMacroDesignView::beforeCellChanged() colnum=" << colnum << " newvalue=" << newvalue.toString() << endl; - int rowindex = d->tabledata->tqfindRef(item); + int rowindex = d->tabledata->findRef(item); if(rowindex < 0) { kdWarning() << "KexiMacroDesignView::beforeCellChanged() No such item" << endl; return; @@ -311,7 +311,7 @@ void KexiMacroDesignView::beforeCellChanged(KexiTableItem* item, int colnum, TQV void KexiMacroDesignView::rowUpdated(KexiTableItem* item) { - int rowindex = d->tabledata->tqfindRef(item); + int rowindex = d->tabledata->findRef(item); kdDebug() << "KexiMacroDesignView::rowUpdated() rowindex=" << rowindex << endl; //propertySetSwitched(); //propertySetReloaded(true); @@ -452,7 +452,7 @@ void KexiMacroDesignView::propertyChanged(KoProperty::Set& set, KoProperty::Prop continue; } - if(! set.tqcontains( (*it).latin1() )) { + if(! set.contains( (*it).latin1() )) { // If there exist no such property yet, we need to add it. if(updateSet(&set, macroitem, *it)) reload = true; // we like to reload the whole set diff --git a/kexi/plugins/macros/lib/action.cpp b/kexi/plugins/macros/lib/action.cpp index db5596b4..45c03d12 100644 --- a/kexi/plugins/macros/lib/action.cpp +++ b/kexi/plugins/macros/lib/action.cpp @@ -124,12 +124,12 @@ void Action::setComment(const TQString& comment) bool Action::hasVariable(const TQString& name) const { - return d->varmap.tqcontains(name); + return d->varmap.contains(name); } KSharedPtr<Variable> Action::variable(const TQString& name) const { - return d->varmap.tqcontains(name) ? d->varmap[name] : KSharedPtr<Variable>(0); + return d->varmap.contains(name) ? d->varmap[name] : KSharedPtr<Variable>(0); } Variable::Map Action::variables() const @@ -145,10 +145,10 @@ TQStringList Action::variableNames() const void Action::setVariable(KSharedPtr<Variable> variable) { const TQString name = variable->name(); - if(! d->varmap.tqcontains(name)) { + if(! d->varmap.contains(name)) { d->varnames.append(name); } - d->varmap.tqreplace(name, variable); + d->varmap.replace(name, variable); } void Action::setVariable(const TQString& name, const TQString& text, const TQVariant& variant) @@ -161,7 +161,7 @@ void Action::setVariable(const TQString& name, const TQString& text, const TQVar void Action::removeVariable(const TQString& name) { - if(d->varmap.tqcontains(name)) { + if(d->varmap.contains(name)) { d->varmap.remove(name); d->varnames.remove(name); } diff --git a/kexi/plugins/macros/lib/context.cpp b/kexi/plugins/macros/lib/context.cpp index 6e2fb2e4..7c0b6ee8 100644 --- a/kexi/plugins/macros/lib/context.cpp +++ b/kexi/plugins/macros/lib/context.cpp @@ -100,14 +100,14 @@ Context::~Context() bool Context::hasVariable(const TQString& name) const { //Use TQMap?s contains to check if a variable with name exists - return d->variables.tqcontains(name); + return d->variables.contains(name); } //return variable with name or throw an exception if none is found in variables KSharedPtr<Variable> Context::variable(const TQString& name) const { //Use TQMap?s contains to check if a variable with name exists in context - if (d->variables.tqcontains(name)) { + if (d->variables.contains(name)) { //return it return d->variables[name]; } @@ -134,7 +134,7 @@ void Context::setVariable(const TQString& name, KSharedPtr<Variable> variable) //debuging infos kdDebug() << TQString("KoMacro::Context::setVariable name='%1' variable='%2'").tqarg(name).tqarg(variable->toString()) << endl; //Use TQMap?s replace to set/replace the variable named name - d->variables.tqreplace(name, variable); + d->variables.replace(name, variable); } //return the associated Macro @@ -252,7 +252,7 @@ void Context::activateNext() } //find the macroitem from which to continue - TQValueList<KSharedPtr<MacroItem > >::ConstIterator it = d->items.tqfind(d->macroitem); + TQValueList<KSharedPtr<MacroItem > >::ConstIterator it = d->items.find(d->macroitem); if (it != d->items.constEnd()) { activate(++it); // try to continue the execution. } diff --git a/kexi/plugins/macros/lib/macroitem.cpp b/kexi/plugins/macros/lib/macroitem.cpp index 471f9660..cf317fab 100644 --- a/kexi/plugins/macros/lib/macroitem.cpp +++ b/kexi/plugins/macros/lib/macroitem.cpp @@ -147,7 +147,7 @@ TQVariant MacroItem::variant(const TQString& name, bool checkaction) const KSharedPtr<Variable> MacroItem::variable(const TQString& name, bool checkaction) const { - if(d->variables.tqcontains(name)) + if(d->variables.contains(name)) return d->variables[name]; if(checkaction && d->action.data()) return d->action->variable(name); @@ -179,7 +179,7 @@ bool MacroItem::setVariant(const TQString& name, const TQVariant& variant) variable = KSharedPtr<Variable>( new Variable() ); variable->setName(name); - d->variables.tqreplace(name, variable); + d->variables.replace(name, variable); } // Remember the previous value for the case we like to restore it. @@ -203,13 +203,13 @@ bool MacroItem::setVariant(const TQString& name, const TQVariant& variant) KSharedPtr<Variable> MacroItem::addVariable(const TQString& name, const TQVariant& variant) { - Q_ASSERT(! d->variables.tqcontains(name) ); + Q_ASSERT(! d->variables.contains(name) ); // Create a new Variable. KSharedPtr<Variable> variable = KSharedPtr<Variable>( new Variable() ); variable->setName(name); // Put it into the Variable-map. - d->variables.tqreplace(name, variable); + d->variables.replace(name, variable); // Set the variant of the Variable. this->setVariant(name, variant); diff --git a/kexi/plugins/macros/lib/manager.cpp b/kexi/plugins/macros/lib/manager.cpp index 0a0d59e0..f73ddaa8 100644 --- a/kexi/plugins/macros/lib/manager.cpp +++ b/kexi/plugins/macros/lib/manager.cpp @@ -85,11 +85,11 @@ Manager::Manager(KXMLGUIClient* const xmlguiclient) kdDebug() << "Manager::Manager() Ctor" << endl; TQObject* obj = dynamic_cast<TQObject*>(xmlguiclient); if(obj) { - d->objects.tqreplace(obj->name(), obj); + d->objects.replace(obj->name(), obj); } //TESTCASE - d->objects.tqreplace("TestCase", new TQWidget()); + d->objects.replace("TestCase", new TQWidget()); } Manager::~Manager() @@ -105,7 +105,7 @@ KXMLGUIClient* Manager::guiClient() const bool Manager::hasMacro(const TQString& macroname) { - return d->macros.tqcontains(macroname); + return d->macros.contains(macroname); } KSharedPtr<Macro> Manager::getMacro(const TQString& macroname) @@ -115,7 +115,7 @@ KSharedPtr<Macro> Manager::getMacro(const TQString& macroname) void Manager::addMacro(const TQString& macroname, KSharedPtr<Macro> macro) { - d->macros.tqreplace(macroname, macro); + d->macros.replace(macroname, macro); } void Manager::removeMacro(const TQString& macroname) @@ -147,16 +147,16 @@ TQStringList Manager::actionNames() const void Manager::publishAction(KSharedPtr<Action> action) { const TQString name = action->name(); - if(! d->actions.tqcontains(name)) { + if(! d->actions.contains(name)) { d->actionnames.append(name); } - d->actions.tqreplace(name, action); + d->actions.replace(name, action); } void Manager::publishObject(const TQString& name, TQObject* object) { - Q_ASSERT(! d->objects.tqcontains(name)); - d->objects.tqreplace(name, object); + Q_ASSERT(! d->objects.contains(name)); + d->objects.replace(name, object); } TQGuardedPtr<TQObject> Manager::object(const TQString& name) const diff --git a/kexi/plugins/macros/lib/manager.h b/kexi/plugins/macros/lib/manager.h index fb332f66..ae32aad9 100644 --- a/kexi/plugins/macros/lib/manager.h +++ b/kexi/plugins/macros/lib/manager.h @@ -128,7 +128,7 @@ namespace KoMacro { * Add a new \a Macro to the list of known macros. If * there exists already a \a Macro instance with the * defined \p macroname then the already existing one - * will be tqreplace. + * will be replace. * * \param macroname The name the \a Macro will be * accessible as. diff --git a/kexi/plugins/macros/lib/metamethod.cpp b/kexi/plugins/macros/lib/metamethod.cpp index 979202e8..16b93803 100644 --- a/kexi/plugins/macros/lib/metamethod.cpp +++ b/kexi/plugins/macros/lib/metamethod.cpp @@ -89,8 +89,8 @@ MetaMethod::MetaMethod(const TQString& signature, Type type, KSharedPtr<MetaObje d->object = object; d->type = type; - int startpos = d->signature.tqfind("("); - int endpos = d->signature.tqfindRev(")"); + int startpos = d->signature.find("("); + int endpos = d->signature.findRev(")"); if(startpos < 0 || startpos > endpos) { throw Exception(TQString("Invalid signature \"%1\"").tqarg(d->signature)); } @@ -103,14 +103,14 @@ MetaMethod::MetaMethod(const TQString& signature, Type type, KSharedPtr<MetaObje d->signaturearguments = d->signature.mid(startpos + 1, endpos - startpos - 1).stripWhiteSpace(); do { - int commapos = d->signaturearguments.tqfind(","); - int starttemplatepos = d->signaturearguments.tqfind("<"); + int commapos = d->signaturearguments.find(","); + int starttemplatepos = d->signaturearguments.find("<"); if(starttemplatepos >= 0 && (commapos < 0 || starttemplatepos < commapos)) { - int endtemplatepos = d->signaturearguments.tqfind(">", starttemplatepos); + int endtemplatepos = d->signaturearguments.find(">", starttemplatepos); if(endtemplatepos <= 0) { throw Exception(TQString("No closing template-definiton in signature \"%1\"").tqarg(d->signature)); } - commapos = d->signaturearguments.tqfind(",", endtemplatepos); + commapos = d->signaturearguments.find(",", endtemplatepos); } if(commapos > 0) { diff --git a/kexi/plugins/macros/tests/xmlhandlertests.cpp b/kexi/plugins/macros/tests/xmlhandlertests.cpp index a08ff33d..29c53831 100644 --- a/kexi/plugins/macros/tests/xmlhandlertests.cpp +++ b/kexi/plugins/macros/tests/xmlhandlertests.cpp @@ -177,7 +177,7 @@ void XMLHandlerTests::testCorrectDomElement() // Test the Compare-method when a Variable will change, it must fail. macro->items().first()->variable("teststring")->setVariant("bla"); - isvariableok.tqreplace("teststring",false); + isvariableok.replace("teststring",false); assertMacroContentEqToXML(macro,elem,false,true,isvariableok); } @@ -568,12 +568,12 @@ void XMLHandlerTests::assertMacroContentEqToXML(const KSharedPtr<KoMacro::Macro> while ( ! varnode.isNull()) { const TQDomElement varelem = varnode.toElement(); - const KSharedPtr<KoMacro::Variable> varitem = mvariables.tqfind(varelem.attribute("name")).data(); + const KSharedPtr<KoMacro::Variable> varitem = mvariables.find(varelem.attribute("name")).data(); //3.comparison - Is the content of the Variable // in the MacroItem and and item equal? { - const bool var = *isvariableok.tqfind(varelem.attribute("name")); + const bool var = *isvariableok.find(varelem.attribute("name")); if( ! var ) { KOMACROTEST_XASSERT(varitem->variant() == TQVariant(varelem.text()), !var); kdDebug() << "The content of the Variable: " << varitem->name() diff --git a/kexi/plugins/queries/kexiquerydesignerguieditor.cpp b/kexi/plugins/queries/kexiquerydesignerguieditor.cpp index 5be54145..be16b70d 100644 --- a/kexi/plugins/queries/kexiquerydesignerguieditor.cpp +++ b/kexi/plugins/queries/kexiquerydesignerguieditor.cpp @@ -318,7 +318,7 @@ void KexiQueryDesignerGuiEditor::updateColumnsData() { //table /*! @todo what about query? */ - KexiDB::TableSchema *table = d->relations->tables()->tqfind(*it)->schema()->table(); + KexiDB::TableSchema *table = d->relations->tables()->find(*it)->schema()->table(); d->conn->registerForTableSchemaChanges(*tempData(), *table); //this table will be used item = d->tablesColumnData->createItem(); //new KexiTableItem(2); (*item)[COLUMN_ID_COLUMN]=table->name(); @@ -961,7 +961,7 @@ void KexiQueryDesignerGuiEditor::showFieldsOrRelationsForQueryInternal( if (column) { //sorting for visible column if (column->visible) { - if (columnsOrder.tqcontains(column)) { + if (columnsOrder.contains(column)) { const int columnPosition = columnsOrder[ column ]; rowItem = d->data->at( columnPosition ); rowPropertySet = d->sets->at( columnPosition ); @@ -1018,7 +1018,7 @@ void KexiQueryDesignerGuiEditor::showFieldsOrRelationsForQueryInternal( } } KexiDB::Field* field = 0; - if (-1 == columnNameArgument->name.tqfind('.') && query->tables()->count()==1) { + if (-1 == columnNameArgument->name.find('.') && query->tables()->count()==1) { //extreme case: only field name provided for one-table query: field = query->tables()->first()->field(columnNameArgument->name); } @@ -1374,9 +1374,9 @@ KexiQueryDesignerGuiEditor::parseExpressionString(const TQString& fullString, in //number TQString decimalSym = KGlobal::locale()->decimalSymbol(); bool ok; - int pos = str.tqfind('.'); + int pos = str.find('.'); if (pos==-1) {//second chance: local decimal symbol - pos = str.tqfind(decimalSym); + pos = str.find(decimalSym); } if (pos>=0) {//real const number const int left = str.left(pos).toInt(&ok); @@ -1440,8 +1440,8 @@ void KexiQueryDesignerGuiEditor::slotBeforeCellChanged(KexiTableItem *item, int //this value is entered by hand and doesn't match //any value in the combo box -- we're assuming this is an expression //-table remains null - //-tqfind "alias" in something like "alias : expr" - const int id = fieldId.tqfind(':'); + //-find "alias" in something like "alias : expr" + const int id = fieldId.find(':'); if (id>0) { alias = fieldId.left(id).stripWhiteSpace().latin1(); if (!KexiUtils::isIdentifier(alias)) { @@ -1490,7 +1490,7 @@ void KexiQueryDesignerGuiEditor::slotBeforeCellChanged(KexiTableItem *item, int KoProperty::Set *set = d->sets->findPropertySetForItem(*item); //*propertyBuffer(); if (!set) { saveOldValue = false; // no old val. - const int row = d->data->tqfindRef(item); + const int row = d->data->findRef(item); if (row<0) { result->success = false; return; @@ -1605,7 +1605,7 @@ void KexiQueryDesignerGuiEditor::slotBeforeCellChanged(KexiTableItem *item, int field = (*set)["field"].value().toString(); table = (*set)["table"].value().toString(); } - if (!str.isEmpty() && (!set || table=="*" || field.tqfind("*")!=-1)) { + if (!str.isEmpty() && (!set || table=="*" || field.find("*")!=-1)) { //asterisk found! criteria not allowed result->success = false; result->allowToDiscardChanges = true; diff --git a/kexi/plugins/queries/kexiquerydesignersqlhistory.cpp b/kexi/plugins/queries/kexiquerydesignersqlhistory.cpp index 19c0e06a..0321ff2b 100644 --- a/kexi/plugins/queries/kexiquerydesignersqlhistory.cpp +++ b/kexi/plugins/queries/kexiquerydesignersqlhistory.cpp @@ -83,7 +83,7 @@ KexiQueryDesignerSQLHistory::contentsMousePressEvent(TQMouseEvent * e) updateContents(it.current()->tqgeometry(y, visibleWidth(), fontMetrics())); } - if(it.current()->tqgeometry(y, visibleWidth(), fontMetrics()).tqcontains(e->pos())) + if(it.current()->tqgeometry(y, visibleWidth(), fontMetrics()).contains(e->pos())) { popupHistory = it.current(); pos = y; @@ -273,12 +273,12 @@ HistoryEntry::highlight(const TQColorGroup &cg) bool dblquote = false; statement = m_statement; - statement.tqreplace("<", "<"); - statement.tqreplace(">", ">"); - statement.tqreplace("\r\n", "<br>"); //(js) first win32 specific pair - statement.tqreplace("\n", "<br>"); // now single \n - statement.tqreplace(" ", " "); - statement.tqreplace("\t", " "); + statement.replace("<", "<"); + statement.replace(">", ">"); + statement.replace("\r\n", "<br>"); //(js) first win32 specific pair + statement.replace("\n", "<br>"); // now single \n + statement.replace(" ", " "); + statement.replace("\t", " "); // getting quoting... if(!m_selected) @@ -331,7 +331,7 @@ HistoryEntry::highlight(const TQColorGroup &cg) TQRegExp keywords("\\b(SELECT|UPDATE|INSERT|DELETE|DROP|FROM|WHERE|AND|OR|NOT|NULL|JOIN|LEFT|RIGHT|ON|INTO|TABLE)\\b"); keywords.setCaseSensitive(false); - text = text.tqreplace(keywords, "<b>\\1</b>"); + text = text.replace(keywords, "<b>\\1</b>"); if(!m_error.isEmpty()) // text += ("<br>"+i18n("Error: %1").tqarg(m_error)); diff --git a/kexi/plugins/scripting/kexidb.doxyfile b/kexi/plugins/scripting/kexidb.doxyfile index 3e21f7f1..f44e8230 100644 --- a/kexi/plugins/scripting/kexidb.doxyfile +++ b/kexi/plugins/scripting/kexidb.doxyfile @@ -16,7 +16,7 @@ ABBREVIATE_BRIEF = "The $name class" \ is \ provides \ specifies \ - tqcontains \ + contains \ represents \ a \ an \ diff --git a/kexi/plugins/scripting/kexidb/kexidbcursor.cpp b/kexi/plugins/scripting/kexidb/kexidbcursor.cpp index bb9f53df..b1d335b6 100644 --- a/kexi/plugins/scripting/kexidb/kexidbcursor.cpp +++ b/kexi/plugins/scripting/kexidb/kexidbcursor.cpp @@ -106,8 +106,8 @@ bool KexiDBCursor::setValue(uint index, TQVariant value) } const TQ_LLONG position = m_cursor->at(); - if(! m_modifiedrecords.tqcontains(position)) - m_modifiedrecords.tqreplace(position, new Record(m_cursor)); + if(! m_modifiedrecords.contains(position)) + m_modifiedrecords.replace(position, new Record(m_cursor)); m_modifiedrecords[position]->buffer->insert(*column, value); return true; } diff --git a/kexi/plugins/scripting/kexidb/kexidbschema.cpp b/kexi/plugins/scripting/kexidb/kexidbschema.cpp index aebcbd7e..2ac40342 100644 --- a/kexi/plugins/scripting/kexidb/kexidbschema.cpp +++ b/kexi/plugins/scripting/kexidb/kexidbschema.cpp @@ -154,20 +154,20 @@ bool KexiDBQuerySchema::setWhereExpression(const TQString& whereexpression) { TQRegExp re("[\"',]{1,1}"); while(true) { s.remove(TQRegExp("^[\\s,]+")); - int pos = s.tqfind('='); + int pos = s.find('='); if(pos < 0) break; TQString key = s.left(pos).stripWhiteSpace(); s = s.mid(pos + 1).stripWhiteSpace(); TQString value; - int sp = s.tqfind(re); + int sp = s.find(re); if(sp >= 0) { if(re.cap(0) == ",") { value = s.left(sp).stripWhiteSpace(); s = s.mid(sp+1).stripWhiteSpace(); } else { - int ep = s.tqfind(re.cap(0),sp+1); + int ep = s.find(re.cap(0),sp+1); value = s.mid(sp+1,ep-1); s = s.mid(ep + 1); } diff --git a/kexi/plugins/scripting/kexiscripting/kexiscriptdesignview.cpp b/kexi/plugins/scripting/kexiscripting/kexiscriptdesignview.cpp index 39f84599..50a875b3 100644 --- a/kexi/plugins/scripting/kexiscripting/kexiscriptdesignview.cpp +++ b/kexi/plugins/scripting/kexiscripting/kexiscriptdesignview.cpp @@ -321,7 +321,7 @@ tristate KexiScriptDesignView::storeData(bool /*dontAsk*/) TQMap<TQString, TQVariant>& options = d->scriptaction->getOptions(); TQMap<TQString, TQVariant>::ConstIterator it, end( options.constEnd() ); for( it = options.constBegin(); it != end; ++it) { - if( defoptions.tqcontains(it.key()) ) { // only remember options which the InterpreterInfo knows about... + if( defoptions.contains(it.key()) ) { // only remember options which the InterpreterInfo knows about... scriptelem.setAttribute(it.key(), it.data().toString()); } } diff --git a/kexi/plugins/scripting/scripts/copycenter/CopyCenter.py b/kexi/plugins/scripting/scripts/copycenter/CopyCenter.py index 43fa7e25..bdec927b 100644 --- a/kexi/plugins/scripting/scripts/copycenter/CopyCenter.py +++ b/kexi/plugins/scripting/scripts/copycenter/CopyCenter.py @@ -210,7 +210,7 @@ def runGuiApp(copycenter, name): if filename != "": self.jobfilecombobox.setCurrentText(filename) def escape(self,s): - return s.tqreplace("&", "&").tqreplace("'", "'").tqreplace("<", "<").tqreplace(">", ">").tqreplace('"', """) + return s.replace("&", "&").replace("'", "'").replace("<", "<").replace(">", ">").replace('"', """) def writeOptions(self,writer,pluginname,plugininst): print "CopyJobWidget.writeOptions" @@ -271,7 +271,7 @@ def runGuiApp(copycenter, name): def text(self, columnindex): if columnindex == 1: - if qt.QListViewItem.text(self,0).tqcontains("password"): + if qt.QListViewItem.text(self,0).contains("password"): return "*" * len(str(qt.QListViewItem.text(self,1))) return qt.QListViewItem.text(self,columnindex) return ListViewItem(pluginimpl, self.listview, parentitem, afteritem) diff --git a/kexi/plugins/scripting/scripts/exportxhtml/ExportXHTML.py b/kexi/plugins/scripting/scripts/exportxhtml/ExportXHTML.py index 9febfcdd..d0d1f0cc 100644 --- a/kexi/plugins/scripting/scripts/exportxhtml/ExportXHTML.py +++ b/kexi/plugins/scripting/scripts/exportxhtml/ExportXHTML.py @@ -83,7 +83,7 @@ class HtmlExporter: def htmlescape(self, text): import string - return string.tqreplace(string.tqreplace(string.tqreplace(str(text),'&','&'),'<','<'),'>','>') + return string.replace(string.replace(string.replace(str(text),'&','&'),'<','<'),'>','>') def write(self, output, style): name = self.datasource.name() diff --git a/kexi/plugins/tables/kexitabledesignerview.cpp b/kexi/plugins/tables/kexitabledesignerview.cpp index 2f6cd21c..0e743bd1 100644 --- a/kexi/plugins/tables/kexitabledesignerview.cpp +++ b/kexi/plugins/tables/kexitabledesignerview.cpp @@ -833,7 +833,7 @@ void KexiTableDesignerView::slotBeforeCellChanged( void KexiTableDesignerView::slotRowUpdated(KexiTableItem *item) { - const int row = d->view->KexiDataAwareObjectInterface::data()->tqfindRef(item); + const int row = d->view->KexiDataAwareObjectInterface::data()->findRef(item); if (row < 0) return; @@ -1155,7 +1155,7 @@ void KexiTableDesignerView::slotAboutToDeleteRow( d->primaryKeyExists = false; if (d->addHistoryCommand_in_slotAboutToDeleteRow_enabled) { - const int row = d->view->KexiDataAwareObjectInterface::data()->tqfindRef(&item); + const int row = d->view->KexiDataAwareObjectInterface::data()->findRef(&item); KoProperty::Set *set = row >=0 ? d->sets->at(row) : 0; //set can be 0 here, what means "removing empty row" addHistoryCommand( @@ -1176,7 +1176,7 @@ KexiDB::Field * KexiTableDesignerView::buildField( const KoProperty::Set &set ) while (it!=values.end()) { const TQString propName( it.key() ); - if (d->internalPropertyNames.tqfind(propName.latin1()) || propName.startsWith("this:") + if (d->internalPropertyNames.find(propName.latin1()) || propName.startsWith("this:") || (/*sanity*/propName=="objectType" && KexiDB::Field::BLOB != KexiDB::intToFieldType( set["type"].value().toInt() ))) { TQMap<TQCString, TQVariant>::Iterator it_tmp = it; @@ -1717,7 +1717,7 @@ void KexiTableDesignerView::insertField(int row, KoProperty::Set& set, bool addC void KexiTableDesignerView::insertFieldInternal(int row, KoProperty::Set* set, //const KexiDB::Field& field, const TQString& caption, bool addCommand) { - if (set && (!set->tqcontains("type") || !set->tqcontains("caption"))) { + if (set && (!set->contains("type") || !set->contains("caption"))) { kexipluginswarn << "KexiTableDesignerView::insertField(): no 'type' or 'caption' property in set!" << endl; return; } @@ -1807,7 +1807,7 @@ void KexiTableDesignerView::changeFieldPropertyForRow( int row, return; KoProperty::Set* set = d->sets->at( row ); - if (!set || !set->tqcontains(propertyName)) + if (!set || !set->contains(propertyName)) return; KoProperty::Property &property = set->property(propertyName); if (listData) { @@ -1896,7 +1896,7 @@ void KexiTableDesignerView::changePropertyVisibility( if (row<0) return; KoProperty::Set* set = d->sets->at( row ); - if (!set || !set->tqcontains(propertyName)) + if (!set || !set->contains(propertyName)) return; KoProperty::Property &property = set->property(propertyName); |