[buddypress-trac] [BuddyPress Trac] #6282: Wrong cropping of avatar, if you don't change the selection window.
buddypress-trac
noreply at wordpress.org
Fri Mar 6 18:35:24 UTC 2015
#6282: Wrong cropping of avatar, if you don't change the selection window.
---------------------------+-----------------------------
Reporter: WeddyWood | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: API - Avatars | Version: 2.2.1
Severity: normal | Keywords:
---------------------------+-----------------------------
The problem occurs if you have uploaded a photo to crop, then did not
change the position and size of window to be circumcised, and then clicked
on the save button. In this case, cropped avatar will be shifted relative
to the center, due to the fact that originally installed the wrong
coordinate values of the window of circumcision.
In file "bp-core-cssjs.php" on lile 166 is wrong calculation of init
coordinates (width & height):
{{{
updateCoords({x: <?php echo (int) $crop_left; ?>, y: <?php echo (int)
$crop_top; ?>, w: <?php echo (int) $crop_right; ?>, h: <?php echo (int)
$crop_bottom; ?>});
}}}
To solve the problem, you just need to delete this line. Javascript (when
the page is initialized itself) will set the correct initial values of the
coordinates of the window for circumcision.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6282>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list