changeset 10476:84ae644933b6

8026476: Choice does not get mouse events if it does not have enough place for popup menu Reviewed-by: anthony, serb Contributed-by: alexander.zvegintsev@oracle.com
author serb
date Fri, 18 Oct 2013 20:35:36 +0400
parents 5334c651c7ba
children d72ca6dac444
files src/solaris/classes/sun/awt/X11/XChoicePeer.java
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/solaris/classes/sun/awt/X11/XChoicePeer.java	Fri Oct 18 15:15:24 2013 +0400
+++ b/src/solaris/classes/sun/awt/X11/XChoicePeer.java	Fri Oct 18 20:35:36 2013 +0400
@@ -814,12 +814,12 @@
                 x = screen.width - width;
             }
 
+            if (y + height > screen.height) {
+                y = global.y - height;
+            }
             if (y < 0) {
                 y = 0;
             }
-            else if (y + height > screen.height) {
-                y = screen.height - height;
-            }
             return new Rectangle(x, y, width, height);
         }