diff options
author | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-18 18:15:24 -0600 |
---|---|---|
committer | Timothy Pearson <kb9vqf@pearsoncomputing.net> | 2011-12-18 18:15:24 -0600 |
commit | 8d9b90ca794ffabf151719c2edebe9278a2d3f36 (patch) | |
tree | 55f446de8694c45be6bf0f1178920c2b92b0c9f5 /src/translators/grs1importer.cpp | |
parent | 2781e27b871150395a5a82e221684108641002b2 (diff) | |
download | tellico-8d9b90ca794ffabf151719c2edebe9278a2d3f36.tar.gz tellico-8d9b90ca794ffabf151719c2edebe9278a2d3f36.zip |
Rename old tq methods that no longer need a unique name
Diffstat (limited to 'src/translators/grs1importer.cpp')
-rw-r--r-- | src/translators/grs1importer.cpp | 42 |
1 files changed, 21 insertions, 21 deletions
diff --git a/src/translators/grs1importer.cpp b/src/translators/grs1importer.cpp index 30c9a69..f987720 100644 --- a/src/translators/grs1importer.cpp +++ b/src/translators/grs1importer.cpp @@ -26,20 +26,20 @@ void GRS1Importer::initTagMap() { if(!s_tagMap) { s_tagMap = new TagMap(); // BT is special and is handled separately - s_tagMap->insert(TagPair(2, 1), TQString::tqfromLatin1("title")); - s_tagMap->insert(TagPair(2, 2), TQString::tqfromLatin1("author")); - s_tagMap->insert(TagPair(2, 4), TQString::tqfromLatin1("year")); - s_tagMap->insert(TagPair(2, 7), TQString::tqfromLatin1("publisher")); - s_tagMap->insert(TagPair(2, 31), TQString::tqfromLatin1("publisher")); - s_tagMap->insert(TagPair(2, 20), TQString::tqfromLatin1("language")); - s_tagMap->insert(TagPair(2, 21), TQString::tqfromLatin1("keyword")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("isbn/issn")), TQString::tqfromLatin1("isbn")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("isbn")), TQString::tqfromLatin1("isbn")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("notes")), TQString::tqfromLatin1("note")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("note")), TQString::tqfromLatin1("note")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("series")), TQString::tqfromLatin1("series")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("physical description")), TQString::tqfromLatin1("note")); - s_tagMap->insert(TagPair(3, TQString::tqfromLatin1("subtitle")), TQString::tqfromLatin1("subtitle")); + s_tagMap->insert(TagPair(2, 1), TQString::fromLatin1("title")); + s_tagMap->insert(TagPair(2, 2), TQString::fromLatin1("author")); + s_tagMap->insert(TagPair(2, 4), TQString::fromLatin1("year")); + s_tagMap->insert(TagPair(2, 7), TQString::fromLatin1("publisher")); + s_tagMap->insert(TagPair(2, 31), TQString::fromLatin1("publisher")); + s_tagMap->insert(TagPair(2, 20), TQString::fromLatin1("language")); + s_tagMap->insert(TagPair(2, 21), TQString::fromLatin1("keyword")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("isbn/issn")), TQString::fromLatin1("isbn")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("isbn")), TQString::fromLatin1("isbn")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("notes")), TQString::fromLatin1("note")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("note")), TQString::fromLatin1("note")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("series")), TQString::fromLatin1("series")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("physical description")), TQString::fromLatin1("note")); + s_tagMap->insert(TagPair(3, TQString::fromLatin1("subtitle")), TQString::fromLatin1("subtitle")); } } @@ -54,12 +54,12 @@ bool GRS1Importer::canImport(int type) const { Tellico::Data::CollPtr GRS1Importer::collection() { Data::CollPtr coll = new Data::BibtexCollection(true); - Data::FieldPtr f = new Data::Field(TQString::tqfromLatin1("isbn"), i18n("ISBN#")); + Data::FieldPtr f = new Data::Field(TQString::fromLatin1("isbn"), i18n("ISBN#")); f->setCategory(i18n("Publishing")); f->setDescription(i18n("International Standard Book Number")); coll->addField(f); - f = new Data::Field(TQString::tqfromLatin1("language"), i18n("Language")); + f = new Data::Field(TQString::fromLatin1("language"), i18n("Language")); f->setCategory(i18n("Publishing")); f->setFlags(Data::Field::AllowCompletion | Data::Field::AllowGrouped | Data::Field::AllowMultiple); coll->addField(f); @@ -68,10 +68,10 @@ Tellico::Data::CollPtr GRS1Importer::collection() { bool empty = true; // in format "(tag, tag) value" - TQRegExp rx(TQString::tqfromLatin1("\\s*\\((\\d+),\\s*(.+)\\s*\\)\\s*(.+)\\s*")); + TQRegExp rx(TQString::fromLatin1("\\s*\\((\\d+),\\s*(.+)\\s*\\)\\s*(.+)\\s*")); // rx.setMinimal(true); - TQRegExp dateRx(TQString::tqfromLatin1(",[^,]*\\d{3,4}[^,]*")); // remove dates from authors - TQRegExp pubRx(TQString::tqfromLatin1("([^:]+):([^,]+),?")); // split location and publisher + TQRegExp dateRx(TQString::fromLatin1(",[^,]*\\d{3,4}[^,]*")); // remove dates from authors + TQRegExp pubRx(TQString::fromLatin1("([^:]+):([^,]+),?")); // split location and publisher bool ok; int n; @@ -109,14 +109,14 @@ Tellico::Data::CollPtr GRS1Importer::collection() { } else if(field == Latin1Literal("publisher")) { int pos = val.find(pubRx); if(pos > -1) { - e->setField(TQString::tqfromLatin1("address"), pubRx.cap(1)); + e->setField(TQString::fromLatin1("address"), pubRx.cap(1)); val = pubRx.cap(2); } } tmp = e->field(field); if(!tmp.isEmpty()) { - tmp += TQString::tqfromLatin1("; "); + tmp += TQString::fromLatin1("; "); } e->setField(field, tmp + val); } |