Author: uncleringo
Date: 2010-08-31 15:34:47 +0200 (Tue, 31 Aug 2010)
New Revision: 30791
Modified:
plugins/sfDoctrineJCroppablePlugin/trunk/lib/doctrine/JCroppable.php
Log:
Fixed bug with cropper image height not getting set correctly
Modified: plugins/sfDoctrineJCroppablePlugin/trunk/lib/doctrine/JCroppable.php
===================================================================
--- plugins/sfDoctrineJCroppablePlugin/trunk/lib/doctrine/JCroppable.php
2010-08-31 13:23:50 UTC (rev 30790)
+++ plugins/sfDoctrineJCroppablePlugin/trunk/lib/doctrine/JCroppable.php
2010-08-31 13:34:47 UTC (rev 30791)
@@ -349,14 +349,9 @@
$img->saveAs($dir . DIRECTORY_SEPARATOR . $original);
}
- if($img->getWidth() > 400)
- {
- $img->resize(400, null);
- }
- else{
- $height = ($img->getHeight() / $img->getWidth() ) * 400;
- $img->resize(400, $height);
- }
+
+ $height = ($img->getHeight() / $img->getWidth() ) * 400;
+ $img->resize(400, $height);
$img->saveAs($dir . DIRECTORY_SEPARATOR . $editable);
--
You received this message because you are subscribed to the Google Groups
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/symfony-svn?hl=en.