Author: manaRH
Date: 2011-08-17 11:02:19 -0400 (Wed, 17 Aug 2011)
New Revision: 14152
Modified:
branches/community/Seam_2_3/jboss-seam-ui/src/main/java/org/jboss/seam/ui/graphicImage/Image.java
Log:
JBSEAM-4833 - fixed integers division ending in float variable
Modified:
branches/community/Seam_2_3/jboss-seam-ui/src/main/java/org/jboss/seam/ui/graphicImage/Image.java
===================================================================
---
branches/community/Seam_2_3/jboss-seam-ui/src/main/java/org/jboss/seam/ui/graphicImage/Image.java 2011-08-17
15:01:45 UTC (rev 14151)
+++
branches/community/Seam_2_3/jboss-seam-ui/src/main/java/org/jboss/seam/ui/graphicImage/Image.java 2011-08-17
15:02:19 UTC (rev 14152)
@@ -325,8 +325,8 @@
public Image scaleToFit(int height, int width)
throws IOException
{
- float hratio = height/getHeight();
- float wratio = width/getWidth();
+ float hratio = (float) height/getHeight();
+ float wratio = (float) width/getWidth();
if (hratio < wratio) {
return scaleToHeight(height);