summaryrefslogtreecommitdiffstats
path: root/settings/js/personal.js
diff options
context:
space:
mode:
authorRobin Appelman <robin@icewind.nl>2016-10-20 16:23:54 +0200
committerRobin Appelman <robin@icewind.nl>2016-10-20 16:23:54 +0200
commit9983b5533a689845d24013d601bf717dd4a302aa (patch)
tree2cdc25aa504f4f5771fc0e3df7186468e2538510 /settings/js/personal.js
parent5a44b70efccca4a5028dee26e09dfd00a9038f53 (diff)
downloadnextcloud-server-9983b5533a689845d24013d601bf717dd4a302aa.tar.gz
nextcloud-server-9983b5533a689845d24013d601bf717dd4a302aa.zip
float the avatar cropper over the page
Signed-off-by: Robin Appelman <robin@icewind.nl>
Diffstat (limited to 'settings/js/personal.js')
-rw-r--r--settings/js/personal.js6
1 files changed, 2 insertions, 4 deletions
diff --git a/settings/js/personal.js b/settings/js/personal.js
index 9f4a4f377b3..213af93a0fe 100644
--- a/settings/js/personal.js
+++ b/settings/js/personal.js
@@ -130,8 +130,8 @@ function updateAvatar (hidedefault) {
function showAvatarCropper () {
var $cropper = $('#cropper');
var $cropperImage = $('<img/>');
- $cropperImage.css('opacity', 0);
- $cropper.prepend($cropperImage);
+ $cropperImage.css('opacity', 0); // prevent showing the unresized image
+ $cropper.children('.inner-container').prepend($cropperImage);
$cropperImage.attr('src',
OC.generateUrl('/avatar/tmp') + '?requesttoken=' + encodeURIComponent(oc_requesttoken) + '#' + Math.floor(Math.random() * 1000));
@@ -148,8 +148,6 @@ function showAvatarCropper () {
boxHeight: 500,
boxWidth: 500,
setSelect: [0, 0, 300, 300]
- }, function() {
- $cropperImage.css('opacity', 1);
});
});
}