summaryrefslogtreecommitdiffstats
path: root/core/js/jquery.avatar.js
diff options
context:
space:
mode:
authorRobin Appelman <icewind@owncloud.com>2014-04-04 23:35:32 +0200
committerRobin Appelman <icewind@owncloud.com>2014-04-04 23:35:32 +0200
commit3c35e82a37de2e442b275ee8047b7507d2bd6cfd (patch)
tree161acf6089eb9167afe8153819b33a5c6e1e44a2 /core/js/jquery.avatar.js
parent710bbd34912b02d7b9a431bb9ff85f22a1475248 (diff)
downloadnextcloud-server-3c35e82a37de2e442b275ee8047b7507d2bd6cfd.tar.gz
nextcloud-server-3c35e82a37de2e442b275ee8047b7507d2bd6cfd.zip
use high resolution avatars on highdpi screens
Diffstat (limited to 'core/js/jquery.avatar.js')
-rw-r--r--core/js/jquery.avatar.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/core/js/jquery.avatar.js b/core/js/jquery.avatar.js
index 381c42d9dbb..7c19cb321fe 100644
--- a/core/js/jquery.avatar.js
+++ b/core/js/jquery.avatar.js
@@ -77,7 +77,7 @@
var url = OC.generateUrl(
'/avatar/{user}/{size}?requesttoken={requesttoken}',
- {user: user, size: size, requesttoken: oc_requesttoken});
+ {user: user, size: size * window.devicePixelRatio, requesttoken: oc_requesttoken});
$.get(url, function(result) {
if (typeof(result) === 'object') {
@@ -93,9 +93,9 @@
} else {
$div.show();
if (ie8fix === true) {
- $div.html('<img src="'+url+'#'+Math.floor(Math.random()*1000)+'">');
+ $div.html('<img width="' + size + '" height="' + size + '" src="'+url+'#'+Math.floor(Math.random()*1000)+'">');
} else {
- $div.html('<img src="'+url+'">');
+ $div.html('<img width="' + size + '" height="' + size + '" src="'+url+'">');
}
}
if(typeof callback === 'function') {