changeset 13000:beeb6378dd37

7173487: closed/java/awt/Frame/RemoveNotifyTest/RemoveNotifyTest.html Reviewed-by: anthony, dcherepanov, serb
author kizune
date Sat, 09 Jun 2012 19:18:24 +0400
parents d0cec5582bd7
children afa8e122dcce
files jdk/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java
diffstat 1 files changed, 5 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/jdk/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Sat Jun 09 17:42:46 2012 +0400
+++ b/jdk/src/macosx/classes/sun/lwawt/macosx/LWCToolkit.java	Sat Jun 09 19:18:24 2012 +0400
@@ -361,9 +361,11 @@
             CWrapper.NSObject.release(screen);
         }
         // Convert between Cocoa's coordinate system and Java.
-        return new Insets(fullScreen.height - workArea.height - workArea.y,
-                          workArea.x, workArea.y,
-                          fullScreen.width - workArea.width - workArea.x);
+        int bottom = workArea.y - fullScreen.y;
+        int top = fullScreen.height - workArea.height - bottom;
+        int left = workArea.x - fullScreen.x;
+        int right = fullScreen.width - workArea.width - left;
+        return  new Insets(top, left, bottom, right);
     }
 
     @Override