From: <ni...@us...> - 2010-07-31 22:34:15
|
Revision: 13806 http://jmol.svn.sourceforge.net/jmol/?rev=13806&view=rev Author: nicove Date: 2010-07-31 22:34:09 +0000 (Sat, 31 Jul 2010) Log Message: ----------- Java 1.5 : Generics Modified Paths: -------------- trunk/Jmol/src/org/jmol/g3d/Graphics3D.java Modified: trunk/Jmol/src/org/jmol/g3d/Graphics3D.java =================================================================== --- trunk/Jmol/src/org/jmol/g3d/Graphics3D.java 2010-07-31 22:33:06 UTC (rev 13805) +++ trunk/Jmol/src/org/jmol/g3d/Graphics3D.java 2010-07-31 22:34:09 UTC (rev 13806) @@ -2082,8 +2082,7 @@ return 0; } } - Integer boxedArgb = (Integer) mapJavaScriptColors.get(strColor - .toLowerCase()); + Integer boxedArgb = mapJavaScriptColors.get(strColor.toLowerCase()); return (boxedArgb == null ? 0 : boxedArgb.intValue()); } @@ -2823,7 +2822,7 @@ 0xFFF6F675, // yellowtint }; - private static final Hashtable mapJavaScriptColors = new Hashtable(); + private static final Hashtable<String, Integer> mapJavaScriptColors = new Hashtable<String, Integer>(); static { for (int i = colorNames.length; --i >= 0; ) mapJavaScriptColors.put(colorNames[i], Integer.valueOf(colorArgbs[i])); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |