[Pkg-owncloud-commits] [owncloud] 397/457: Determine the size we need before asking for a thumbnail We need to set the size of the preview using the devicePixelRatio and use that as arguments when using the preview endpoint or that endpoint will use the default 36x36 and thumbnails will be blurry on high DPI devices

David Prévot taffit at moszumanska.debian.org
Sun Jun 28 20:06:54 UTC 2015


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch stable8
in repository owncloud.

commit 8ff4a66f0150624b8b08c4c47765016bd2e3a2ab
Author: Olivier Paroz <github at oparoz.com>
Date:   Fri Jun 12 18:50:21 2015 +0200

    Determine the size we need before asking for a thumbnail
    We need to set the size of the preview using the devicePixelRatio and use that as arguments when using the preview endpoint or that endpoint will use the default 36x36 and thumbnails will be blurry on high DPI devices
---
 apps/files_sharing/js/public.js | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/apps/files_sharing/js/public.js b/apps/files_sharing/js/public.js
index 6261c70..32a4694 100644
--- a/apps/files_sharing/js/public.js
+++ b/apps/files_sharing/js/public.js
@@ -159,6 +159,8 @@ OCA.Sharing.PublicApp = {
 
 			this.fileList.generatePreviewUrl = function (urlSpec) {
 				urlSpec.t = $('#dirToken').val();
+				urlSpec.y = 36 * window.devicePixelRatio;
+				urlSpec.x = 36 * window.devicePixelRatio;
 				return OC.generateUrl('/apps/files_sharing/ajax/publicpreview.php?') + $.param(urlSpec);
 			};
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-owncloud/owncloud.git



More information about the Pkg-owncloud-commits mailing list