diff options
author | Slávek Banko <[email protected]> | 2014-03-03 13:46:44 +0100 |
---|---|---|
committer | Slávek Banko <[email protected]> | 2014-03-03 13:46:44 +0100 |
commit | 2e02da046d3e56cdf4744f644af35ad07424f48b (patch) | |
tree | f2dcf353aa2338eae1c2ff2c41af971c580c2762 /src/translators/deliciousimporter.cpp | |
parent | 3c13229d98167ae4ae0710d5eeef23fef5005bf0 (diff) | |
download | tellico-2e02da046d3e56cdf4744f644af35ad07424f48b.tar.gz tellico-2e02da046d3e56cdf4744f644af35ad07424f48b.zip |
Update to upstream version 1.3.6
Diffstat (limited to 'src/translators/deliciousimporter.cpp')
-rw-r--r-- | src/translators/deliciousimporter.cpp | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/src/translators/deliciousimporter.cpp b/src/translators/deliciousimporter.cpp index a82c006..be6fe3e 100644 --- a/src/translators/deliciousimporter.cpp +++ b/src/translators/deliciousimporter.cpp @@ -35,7 +35,9 @@ DeliciousImporter::DeliciousImporter(const KURL& url_) : XSLTImporter(url_) { } bool DeliciousImporter::canImport(int type) const { - return type == Data::Collection::Book; + return type == Data::Collection::Book || + type == Data::Collection::Video || + type == Data::Collection::Game; } Tellico::Data::CollPtr DeliciousImporter::collection() { @@ -51,7 +53,18 @@ Tellico::Data::CollPtr DeliciousImporter::collection() { << TQString::fromLatin1("Medium Covers/") << TQString::fromLatin1("Small Covers/") << TQString::fromLatin1("Plain Covers/"); - const TQString commField = TQString::fromLatin1("comments"); + TQString commField; + switch(coll->type()) { + case Data::Collection::Book: + commField = TQString::fromLatin1("comments"); break; + case Data::Collection::Video: + commField = TQString::fromLatin1("plot"); break; + case Data::Collection::Game: + commField = TQString::fromLatin1("description"); break; + default: + myWarning() << "bad collection type:" << coll->type() << endl; + } + const TQString uuidField = TQString::fromLatin1("uuid"); const TQString coverField = TQString::fromLatin1("cover"); const bool isLocal = url().isLocalFile(); |