From: <gda...@us...> - 2014-10-08 15:00:28
|
Revision: 2868 http://sourceforge.net/p/abbot/svn/2868 Author: gdavison Date: 2014-10-08 15:00:23 +0000 (Wed, 08 Oct 2014) Log Message: ----------- Bail in focus if the window is focused, to prevent intermittent failures on JDK 8 Modified Paths: -------------- abbot/trunk/src/abbot/tester/Robot.java Modified: abbot/trunk/src/abbot/tester/Robot.java =================================================================== --- abbot/trunk/src/abbot/tester/Robot.java 2014-08-20 14:55:12 UTC (rev 2867) +++ abbot/trunk/src/abbot/tester/Robot.java 2014-10-08 15:00:23 UTC (rev 2868) @@ -525,10 +525,22 @@ /** Move keyboard focus to the given component. */ public void focus(final Component comp, boolean wait) { + + if (comp instanceof Window) + { + Window focusedWindow = AWT.getFocusedWindow(); + if (comp == focusedWindow) { + return; + } + } + Component currentOwner = AWT.getFocusOwner(); if (currentOwner == comp) { return; } + + + Log.debug("Focus change"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |