On 3/19/2015 2:03 PM, Anton V. Tarasov wrote:
Hi Alexander, Sergey,

I can't say exactly if this is ok to init AWT from that point, but even if it is, this seems to introduce new risks. At the same time, AFAICS, the root of the original focus problem is unknown. Is that the case? Should we try to understand it, instead? It is possible that fixing the root of the issue would be less risky.

It is new requirement that NSApplication should be initialized before NSScreen using on Mac OS X 10.10 Yosemite:
  -----------------------------
NSScreen should be called the first time from the main thread (usually as part of -[NSApplication init]) to maintain consistency. (
  0 AppKit 0x00007fff84c1609a +[NSScreen _prepare] + 56
  1 libobjc.A.dylib 0x00007fff8f2e0bd0 _class_initialize + 655
  -----------------------------

   In our case it should be [NSApplicationAWT init].

I can't dig deeper in it because problem is in between intersection of NSScreen initialization and [JRSAppKitAWT registrationOptions: options] calls on Mac OS X Yosemite. Both of them do not have public sources.

Which risks do you mean? [NSApplicationAWT sharedApplication] is called from the SplashInitPlatform() method during splash screen creation so we just initialize the NSApplicationAWT a bit earlier.

  Thanks,
  Alexandr.


Thanks,
Anton.

On 17.03.2015 14:27, Alexander Scherbatiy wrote:

Hello,

Could you review the fix:
  bug: https://bugs.openjdk.java.net/browse/JDK-8075244
  webrev: http://cr.openjdk.java.net/~alexsch/8075244/webrev.00

[NSApplicationAWT sharedApplication] call is added for the application initialization.

Thanks,
Alexandr.



Reply via email to