diff sidebar/js/tab-collection-manager.js @ 1:b0827360b8e4

Store favicons and thumbnails in local database
author Guido Berhoerster <guido+set-aside@berhoerster.name>
date Mon, 19 Nov 2018 17:26:17 +0100
parents d13d59494613
children 49ec0da1e698
line wrap: on
line diff
--- a/sidebar/js/tab-collection-manager.js	Sat Nov 17 10:44:16 2018 +0100
+++ b/sidebar/js/tab-collection-manager.js	Mon Nov 19 17:26:17 2018 +0100
@@ -78,13 +78,14 @@
             tabLinkElement.href = tab.url;
             tabLinkElement.title = tab.title;
 
-            if (tab.thumbnailUrl !== null) {
+            if (tab.thumbnail !== null) {
                 tabItemNode.querySelector('.tab-thumbnail').src =
-                        tab.thumbnailUrl;
+                        URL.createObjectURL(tab.thumbnail);
             }
 
-            if (tab.favIconUrl !== null) {
-                tabItemNode.querySelector('.tab-favicon').src = tab.favIconUrl;
+            if (tab.favIcon !== null) {
+                tabItemNode.querySelector('.tab-favicon').src =
+                        URL.createObjectURL(tab.favIcon);
             }
 
             tabItemNode.querySelector('.tab-title').textContent = tab.title;