7027486: JPopupMenu doesn't take window shape into account

Reviewed-by: rupashka
This commit is contained in:
Alexander Potochkin 2011-03-29 21:02:53 +04:00
parent e7b397be03
commit 6fec1477a3

View File

@ -203,6 +203,12 @@ public class PopupFactory {
popupType = HEAVY_WEIGHT_POPUP;
break;
}
} else if (c instanceof Window) {
Window w = (Window) c;
if (!w.isOpaque() || w.getOpacity() < 1 || w.getShape() != null) {
popupType = HEAVY_WEIGHT_POPUP;
break;
}
}
c = c.getParent();
}