[gnome-books/wip/hadess/add-kf8] main: Declare support for Kindle Format files



commit 25359b4be3e6e2173ebe791686af4e74543777ce
Author: Bastien Nocera <hadess hadess net>
Date:   Wed Oct 23 16:07:56 2019 +0200

    main: Declare support for Kindle Format files
    
    In addition to plain mobi files

 src/documents.js | 1 +
 src/search.js    | 2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)
---
diff --git a/src/documents.js b/src/documents.js
index f419ba6a..b6aea652 100644
--- a/src/documents.js
+++ b/src/documents.js
@@ -706,6 +706,7 @@ const DocCommon = new Lang.Class({
         Utils.debug('Loading ' + this.__name__ + ' ' + this.id + ' from ' + this.uriToLoad);
 
         if (this.mimeType == 'application/x-mobipocket-ebook' ||
+            this.mimeType == 'application/vnd.amazon.mobi8-ebook' ||
             this.mimeType == 'application/x-fictionbook+xml' ||
             this.mimeType == 'application/x-zip-compressed-fb2') {
             let exception = new GLib.Error(Gio.IOErrorEnum,
diff --git a/src/search.js b/src/search.js
index 3872e318..b8e9b593 100644
--- a/src/search.js
+++ b/src/search.js
@@ -125,7 +125,7 @@ const SearchTypeManager = new Lang.Class({
 
         this.addItem(new SearchType({ id: SearchTypeStock.EBOOKS,
                                       name: _("e-Books"),
-                                      filter: '(nie:mimeType(?urn) IN (\"application/epub+zip\", 
\"application/x-mobipocket-ebook\", \"application/x-fictionbook+xml\", \"application/x-zip-compressed-fb2\", 
\"image/vnd.djvu+multipage\"))',
+                                      filter: '(nie:mimeType(?urn) IN (\"application/epub+zip\", 
\"application/x-mobipocket-ebook\", \"application/vnd.amazon.mobi8-ebook\", 
\"application/x-fictionbook+xml\", \"application/x-zip-compressed-fb2\", \"image/vnd.djvu+multipage\"))',
                                       where: '?urn rdf:type nfo:FileDataObject .' }));
         this.addItem(new SearchType({ id: SearchTypeStock.COMICS,
                                       name: _("Comics"),


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]