diff options
Diffstat (limited to 'kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp')
-rw-r--r-- | kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp b/kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp index b956335b..ec31df35 100644 --- a/kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp +++ b/kword/mailmerge/sql/KWQtSqlSerialDataSource.cpp @@ -22,7 +22,7 @@ #include "KWQtSqlEasyFilter.h" #include <klocale.h> -#include <layout.h> +#include <tqlayout.h> #include <tqsqlcursor.h> #include <tqdatatable.h> #include <tqcheckbox.h> @@ -59,32 +59,32 @@ TQString KWQtSqlSerialDataSource::getValue( const TQString &name, int record ) c if ( num < 0 || num > (int)myquery->size() ) return name; if (!myquery->seek(num,false)) return i18n(">>>Illegal position within datasource<<<"); - if (!myquery->contains(name)) return i18n(">>>Field %1 is unknown in the current database query<<<").arg(name); + if (!myquery->contains(name)) return i18n(">>>Field %1 is unknown in the current database query<<<").tqarg(name); return (myquery->value(name)).toString(); } void KWQtSqlSerialDataSource::save( TQDomDocument & /*doc*/, TQDomElement & /*parent*/) { /* - TQDomElement def=doc.createElement(TQString::fromLatin1("DEFINITION")); + TQDomElement def=doc.createElement(TQString::tqfromLatin1("DEFINITION")); parent.appendChild(def); for (DbRecord::Iterator it=sampleRecord.begin();it!=sampleRecord.end();++it) { - TQDomElement defEnt=doc.createElement(TQString::fromLatin1("FIELD")); - defEnt.setAttribute(TQString::fromLatin1("name"),it.key()); + TQDomElement defEnt=doc.createElement(TQString::tqfromLatin1("FIELD")); + defEnt.setAttribute(TQString::tqfromLatin1("name"),it.key()); def.appendChild(defEnt); } - TQDomElement cont=doc.createElement(TQString::fromLatin1("CONTENT")); + TQDomElement cont=doc.createElement(TQString::tqfromLatin1("CONTENT")); parent.appendChild(cont); for (Db::Iterator dbI=db.begin();dbI!=db.end();++dbI) { - TQDomElement rec=doc.createElement(TQString::fromLatin1("RECORD")); + TQDomElement rec=doc.createElement(TQString::tqfromLatin1("RECORD")); cont.appendChild(rec); for (DbRecord::Iterator it=sampleRecord.begin();it!=sampleRecord.end();++it) { - TQDomElement recEnt=doc.createElement(TQString::fromLatin1("ITEM")); - recEnt.setAttribute(TQString::fromLatin1("name"),it.key()); - recEnt.setAttribute(TQString::fromLatin1("data"),(*dbI)[it.key()]); + TQDomElement recEnt=doc.createElement(TQString::tqfromLatin1("ITEM")); + recEnt.setAttribute(TQString::tqfromLatin1("name"),it.key()); + recEnt.setAttribute(TQString::tqfromLatin1("data"),(*dbI)[it.key()]); rec.appendChild(recEnt); } } @@ -101,7 +101,7 @@ void KWQtSqlSerialDataSource::load( TQDomElement& /*parentElem*/ ) TQDomElement def=defNd.toElement(); for (TQDomElement defEnt=def.firstChild().toElement();!defEnt.isNull();defEnt=defEnt.nextSibling().toElement()) { - sampleRecord[defEnt.attribute(TQString::fromLatin1("name"))]=defEnt.attribute(TQString::fromLatin1("name"));//i18n( "No Value" ); + sampleRecord[defEnt.attribute(TQString::tqfromLatin1("name"))]=defEnt.attribute(TQString::tqfromLatin1("name"));//i18n( "No Value" ); } TQDomNode contNd=parentElem.namedItem("CONTENT"); if (contNd.isNull()) return; @@ -110,8 +110,8 @@ void KWQtSqlSerialDataSource::load( TQDomElement& /*parentElem*/ ) appendRecord(); for (TQDomElement recEnt=rec.firstChild().toElement();!recEnt.isNull();recEnt=recEnt.nextSibling().toElement()) { - setValue(recEnt.attribute(TQString::fromLatin1("name")), - recEnt.attribute(TQString::fromLatin1("data")),db.count()-1); + setValue(recEnt.attribute(TQString::tqfromLatin1("name")), + recEnt.attribute(TQString::tqfromLatin1("data")),db.count()-1); } } */ @@ -146,7 +146,7 @@ void KWQtSqlSerialDataSource::refresh(bool force) myquery->setMode(TQSqlCursor::ReadOnly); myquery->select(filter); } - kdDebug()<<TQString("There were %1 rows in the query").arg(myquery->size())<<endl; + kdDebug()<<TQString("There were %1 rows in the query").tqarg(myquery->size())<<endl; } |