harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ndbe...@apache.org
Subject svn commit: r823949 - /harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java
Date Sat, 10 Oct 2009 21:33:05 GMT
Author: ndbeyer
Date: Sat Oct 10 21:33:05 2009
New Revision: 823949

URL: http://svn.apache.org/viewvc?rev=823949&view=rev
Log:
remove unnecessary else statements

Modified:
    harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java?rev=823949&r1=823948&r2=823949&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java (original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/Font.java Sat
Oct 10 21:33:05 2009
@@ -250,10 +250,9 @@
         if (!FontManager.IS_FONTLIB) {
             //TODO implement true code point support 
             return canDisplay((char)i);
-        } else {
-            FontPeerImpl peer = (FontPeerImpl)this.getPeer();
-            return peer.canDisplay(peer.getUnicodeByIndex(i));
         }
+        FontPeerImpl peer = (FontPeerImpl)this.getPeer();
+        return peer.canDisplay(peer.getUnicodeByIndex(i));
     }
 
     public int canDisplayUpTo(char[] text, int start, int limit) {
@@ -963,13 +962,12 @@
             }
             
             return ((FLFontManager)FontManager.getInstance()).embedFont(fontFile.getAbsolutePath(),
fontFormat);
-        } else {
-            InputStream is = new FileInputStream(fontFile);
-            try {
-                return createFont(fontFormat, is);
-            } finally {
-                is.close();
-            }
+        }
+        InputStream is = new FileInputStream(fontFile);
+        try {
+            return createFont(fontFormat, is);
+        } finally {
+            is.close();
         }
     }
     



Mime
View raw message