diff --git a/js/app.js b/js/app.js index eac578ea..0039aec0 100644 --- a/js/app.js +++ b/js/app.js @@ -1398,6 +1398,7 @@ OC.Contacts = OC.Contacts || { var cropphoto = new Image(); $(cropphoto).load(function () { + var x = 5, y = 5, w = this.width-10, h = this.height-10; $(this).attr('id', 'cropbox'); $(this).prependTo($dlg).fadeIn(); $(this).Jcrop({ @@ -1409,7 +1410,7 @@ OC.Contacts = OC.Contacts || { bgOpacity: .4, boxWidth: 400, boxHeight: 400, - setSelect: [ 100, 130, 50, 50 ]//, + setSelect: [ w, h, x, y ]//, //aspectRatio: 0.8 }); $container.html($dlg).dialog({ @@ -1429,7 +1430,7 @@ OC.Contacts = OC.Contacts || { $container.remove(); }, open: function(event, ui) { - // Jcrop maybe? + showCoords({x:x,y:y,w:w,h:h}); } }); }).error(function () {