JRE-225 [macos] IDEA hangs on attempt to call getDefaultScreenDevice() from EDT

(cherry picked from commit 76aba25)

(cherry picked from commit df11dcc97bb5556ac5d0299b773a512b4f0bb5bb)
(cherry picked from commit aeea6c1ca3)
This commit is contained in:
Anton Tarasov
2017-02-13 18:35:33 +03:00
committed by alexey.ushakov@jetbrains.com
parent cfb6925793
commit 62bc407015

View File

@@ -1251,7 +1251,8 @@ public class SwingUtilities2 {
GraphicsConfiguration gc = c.getGraphicsConfiguration();
AffineTransform tx = (gc == null) ? null : gc.getDefaultTransform();
if (tx == null && !GraphicsEnvironment.isHeadless()) {
// [tav] workaround deadlock on MacOSX until fixed, JRE-226
if (!FontUtilities.isMacOSX && tx == null && !GraphicsEnvironment.isHeadless()) {
tx = GraphicsEnvironment
.getLocalGraphicsEnvironment()
.getDefaultScreenDevice()