harmony-commits mailing list archives

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

URL: http://svn.apache.org/viewvc?rev=823943&view=rev
Log:
add suppression, remove unnecessary suppression, remove unnecessary nul check

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

Modified: harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/KeyboardFocusManager.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/KeyboardFocusManager.java?rev=823943&r1=823942&r2=823943&view=diff
==============================================================================
--- harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/KeyboardFocusManager.java
(original)
+++ harmony/enhanced/classlib/trunk/modules/awt/src/main/java/common/java/awt/KeyboardFocusManager.java
Sat Oct 10 21:22:18 2009
@@ -115,6 +115,7 @@
         DEFAULT_BWD_KS = Collections.unmodifiableSet(s);
     }
 
+    @SuppressWarnings("unchecked")
     public KeyboardFocusManager() {
         traversalKeys = new Set[4];
         traversalKeys[0] = DEFAULT_FWD_KS;
@@ -214,7 +215,6 @@
         }
     }
 
-    @SuppressWarnings("unchecked")
     public Set<AWTKeyStroke> getDefaultFocusTraversalKeys(int id) {
         checkTraversalKeyId(id, 3);
 
@@ -613,10 +613,8 @@
         //        }
         wnd.setRequestedFocus(c);
         setFocus(c, wnd, true, actualPrevFocusOwner, temporary, callCB);
-        if (wnd != null) {
-            wnd.setFocusOwner(c);
-            wnd.setRequestedFocus(null);
-        }
+        wnd.setFocusOwner(c);
+        wnd.setRequestedFocus(null);
         return true;
     }
 



Mime
View raw message