--- old/./test/java/awt/Multiscreen/LocationRelativeToTest/LocationRelativeToTest.java 2010-01-25 17:42:52.000000000 +0100 +++ new/./test/java/awt/Multiscreen/LocationRelativeToTest/LocationRelativeToTest.java 2010-01-25 17:42:52.000000000 +0100 @@ -50,7 +50,8 @@ GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment(); - System.out.println("Center point: " + ge.getCenterPoint()); + Point centerPoint = ge.getCenterPoint(); + System.out.println("Center point: " + centerPoint); GraphicsDevice[] gds = ge.getScreenDevices(); GraphicsDevice gdDef = ge.getDefaultScreenDevice(); GraphicsConfiguration gcDef = @@ -77,8 +78,7 @@ // second, check setLocationRelativeTo(invisible) f.setLocationRelativeTo(f2); Util.waitForIdle(r); - checkLocation(f, new Point(gcBounds.x + gcBounds.width / 2, - gcBounds.y + gcBounds.height / 2)); + checkLocation(f, centerPoint); // third, check setLocationRelativeTo(visible) f2.setVisible(true);