From 716a5de8870d7c02bb4d0aed72f30291b17b763a Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Mon, 19 Dec 2011 11:59:01 -0600 Subject: Remove additional unneeded tq method conversions --- kmail/snippetwidget.cpp | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) (limited to 'kmail/snippetwidget.cpp') diff --git a/kmail/snippetwidget.cpp b/kmail/snippetwidget.cpp index afa610df8..2c81c6d28 100644 --- a/kmail/snippetwidget.cpp +++ b/kmail/snippetwidget.cpp @@ -145,7 +145,7 @@ void SnippetWidget::slotAdd() SnippetItem* SnippetWidget::makeItem( SnippetItem* parent, const TQString& name, const TQString& text, const KShortcut& shortcut ) { SnippetItem * item = new SnippetItem(parent, name, text); - const TQString actionName = i18n("Snippet %1").tqarg(name); + const TQString actionName = i18n("Snippet %1").arg(name); const TQString normalizedName = TQString(actionName).replace(" ", "_"); if ( !mActionCollection->action(normalizedName.utf8().data() ) ) { KAction * action = new KAction( actionName, shortcut, item, @@ -352,8 +352,8 @@ void SnippetWidget::writeConfig() SnippetGroup * group = dynamic_cast(item); if (group) { //kdDebug(5006) << "-->GROUP " << item->getName() << group->getId() << " " << iGroupCount<< endl; - strKeyName=TQString("snippetGroupName_%1").tqarg(iGroupCount); - strKeyId=TQString("snippetGroupId_%1").tqarg(iGroupCount); + strKeyName=TQString("snippetGroupName_%1").arg(iGroupCount); + strKeyId=TQString("snippetGroupId_%1").arg(iGroupCount); _cfg->writeEntry(strKeyName, group->getName()); _cfg->writeEntry(strKeyId, group->getId()); @@ -361,9 +361,9 @@ void SnippetWidget::writeConfig() iGroupCount++; } else if (dynamic_cast(item)) { //kdDebug(5006) << "-->ITEM " << item->getName() << item->getParent() << " " << iSnipCount << endl; - strKeyName=TQString("snippetName_%1").tqarg(iSnipCount); - strKeyText=TQString("snippetText_%1").tqarg(iSnipCount); - strKeyId=TQString("snippetParent_%1").tqarg(iSnipCount); + strKeyName=TQString("snippetName_%1").arg(iSnipCount); + strKeyText=TQString("snippetText_%1").arg(iSnipCount); + strKeyId=TQString("snippetParent_%1").arg(iSnipCount); _cfg->writeEntry(strKeyName, item->getName()); _cfg->writeEntry(strKeyText, item->getText()); @@ -373,7 +373,7 @@ void SnippetWidget::writeConfig() assert( action ); const KShortcut& sc = action->shortcut(); if (!sc.isNull() ) { - _cfg->writeEntry( TQString("snippetShortcut_%1").tqarg(iSnipCount), sc.toString() ); + _cfg->writeEntry( TQString("snippetShortcut_%1").arg(iSnipCount), sc.toString() ); } iSnipCount++; } else { @@ -389,8 +389,8 @@ void SnippetWidget::writeConfig() for ( it = _mapSaved.begin(); it != _mapSaved.end(); ++it ) { //write the saved variable values if (it.data().length()<=0) continue; //is the saved value has no length -> no need to save it - strKeyName=TQString("snippetSavedName_%1").tqarg(iCount); - strKeyText=TQString("snippetSavedVal_%1").tqarg(iCount); + strKeyName=TQString("snippetSavedName_%1").arg(iCount); + strKeyText=TQString("snippetSavedVal_%1").arg(iCount); _cfg->writeEntry(strKeyName, it.key()); _cfg->writeEntry(strKeyText, it.data()); @@ -434,8 +434,8 @@ void SnippetWidget::initConfig() int iCount = _cfg->readNumEntry("snippetGroupCount", -1); for ( int i=0; ireadNumEntry("snippetCount", 0); for ( int i=0; ireadEntry( TQString("snippetShortcut_%1").tqarg(i), TQString() ) ); + KShortcut shortcut( _cfg->readEntry( TQString("snippetShortcut_%1").arg(i), TQString() ) ); item = makeItem( SnippetItem::findGroupById(iParentVal, _list), strNameVal, strTextVal, shortcut ); //kdDebug(5006) << "Created item " << item->getName() << " " << item->getParent() << endl; _list.append(item); @@ -487,8 +487,8 @@ void SnippetWidget::initConfig() iCount = _cfg->readNumEntry("snippetSavedCount", 0); for ( int i=1; i<=iCount; i++) { //read the saved-values and store in TQMap - strKeyName=TQString("snippetSavedName_%1").tqarg(i); - strKeyText=TQString("snippetSavedVal_%1").tqarg(i); + strKeyName=TQString("snippetSavedName_%1").arg(i); + strKeyText=TQString("snippetSavedVal_%1").arg(i); TQString strNameVal=""; TQString strTextVal=""; @@ -586,7 +586,7 @@ TQString SnippetWidget::parseText(TQString text, TQString del) if ( strName != del+del ) { //if not doubel-delimiter if (iInMeth == 0) { //if input-method "single" is selected if ( mapVar[strName].length() <= 0 ) { // and not already in map - strMsg=i18n("Please enter the value for %1:").tqarg(strName); + strMsg=i18n("Please enter the value for %1:").arg(strName); strNew = showSingleVarDialog( strName, &_mapSaved, rSingle ); if (strNew=="") return ""; //user clicked Cancle @@ -729,7 +729,7 @@ bool SnippetWidget::showMultiVarDialog(TQMap * map, TQMap 1) { - TQRect r = dlg.tqgeometry(); + TQRect r = dlg.geometry(); r.setHeight(iBasicHeight + iOneHeight*mapVar2Te.count()); r.setWidth(iWidth); dlg.setGeometry(r); @@ -750,9 +750,9 @@ bool SnippetWidget::showMultiVarDialog(TQMap * map, TQMaptqgeometry().height(); - iOneHeight = layoutVar->tqgeometry().height() / mapVar2Te.count(); - iWidth = dlg.tqgeometry().width(); + iBasicHeight = dlg.geometry().height() - layoutVar->geometry().height(); + iOneHeight = layoutVar->geometry().height() / mapVar2Te.count(); + iWidth = dlg.geometry().width(); } //do some cleanup @@ -799,7 +799,7 @@ TQString SnippetWidget::showSingleVarDialog(TQString var, TQMapaddWidget(labTop, 0, 0); - labTop->setText(i18n("Enter the replacement values for %1:").tqarg( var )); + labTop->setText(i18n("Enter the replacement values for %1:").arg( var )); tqlayout->addMultiCellLayout( layoutTop, 0, 0, 0, 1 ); @@ -849,7 +849,7 @@ TQString SnippetWidget::showSingleVarDialog(TQString var, TQMaptext(); //copy the entered values back the the given map - dlgSize = dlg.tqgeometry(); + dlgSize = dlg.geometry(); } //do some cleanup -- cgit v1.2.1