TagSpaces is an offline, open source, document manager with tagging support
Auto load thumbnails
Borislav Sapundzhiev9b25725e9511
diff --git a/data/ext/perspectiveGrid/perspectiveUI.js b/data/ext/perspectiveGrid/perspectiveUI.jsindex 2eeb3a7b9..aaef1c592 100644--- a/data/ext/perspectiveGrid/perspectiveUI.js+++ b/data/ext/perspectiveGrid/perspectiveUI.js@@ -253,6 +253,8 @@ define(function(require, exports, module) {// Disable all buttonsthis.viewToolbar.find(".btn").prop('disabled', true);++ this.toggleThumbnails();};ExtUI.prototype.switchThumbnailSize = function() {@@ -282,12 +284,17 @@ define(function(require, exports, module) {}});} else {- generateThumbnail($element.attr('filepath'), function(dataURL) {- $element.attr('src', dataURL);- if (($tiltleElem.length - 1) === index) {- TSCORE.hideLoadingAnimation();+ TSCORE.metaFileList.every(function(element) {++ var filePath = $element.attr('filepath') + ".png";+ if (filePath.indexOf(element.name) > 0) {+ var metaFilePath = TSCORE.currentPath + TSCORE.dirSeparator ++ ".ts" + TSCORE.dirSeparator + element.name;+ $element.attr('src', metaFilePath);+ return false;}- });+ return true;+ });}$element.attr('style', "");});diff --git a/data/js/directories.ui.js b/data/js/directories.ui.jsindex 6b7c3ca6f..a8826e3c0 100644--- a/data/js/directories.ui.js+++ b/data/js/directories.ui.js@@ -356,8 +356,10 @@ define(function(require, exports, module) {}console.log('Dir History: ' + JSON.stringify(directoryHistory));TSCORE.currentPath = directoryPath;- if (TSPRO.available && TSCORE.IO.getDirectoryMetaInformation) {- TSCORE.IO.getDirectoryMetaInformation(TSPRO.getMetaDirectoryPath());+ if (TSCORE.IO.getDirectoryMetaInformation) {+ //TODO: get folder name+ var metaFolderPath = TSCORE.currentPath + TSCORE.dirSeparator + ".ts";+ TSCORE.IO.getDirectoryMetaInformation(metaFolderPath);}TSCORE.IO.listDirectory(directoryPath);}