<AWT Dev> <AWT dev>[9] Review request for 8061637: GraphicsEnvironment API does not detect dynamically attached graphics device

Sergey Bylokhov Sergey.Bylokhov at oracle.com
Mon May 23 14:00:56 UTC 2016


On 23.05.16 13:29, Semyon Sadetsky wrote:
> This will not be possible because of deadlock: the SGE update calls D3D,
> which synchronously send messages to the toolkit thread.

Why it is a problem to call this on the toolkit thread directly?

>> I think that XToolkit and LWToolkit should uses this logic already.
> On Windows communication with the graphics pipeline is designed differently.

They are quite similar if not identical. I suggest to check two solutions:
  - displayChanged is on toolkit thread, only listeners which can call 
users code executed on EDT.
  - The main logic on the toolkit thread all listeners are on related 
EDT(in this case we will need to save the appcontext of the listener on 
addDisplayChangedListener()).

>
> --Semyon
>>
>> On 29.04.16 9:56, Semyon Sadetsky wrote:
>>> Hello,
>>>
>>> Please review fix for JDK9:
>>>
>>> bug: https://bugs.openjdk.java.net/browse/JDK-8061637
>>> webrev: http://cr.openjdk.java.net/~ssadetsky/8061637/webrev.00/
>>>
>>> Display reconfiguration notification is skipped by JavaWS and the plugin
>>> under Windows.
>>> This happens because native display change event is scheduled to the
>>> main app context EDT but the last was disabled by 8004584. As result NPE
>>> is thrown on the Toolkit thread and event handling is not scheduled.
>>> The fix solution runs display event handling in a new thread if the
>>> system EDT is not available.
>>> Test would require to write native code so the bug is labeled
>>> noreg-hard.
>>>
>>> --Semyon
>>
>>
>


-- 
Best regards, Sergey.


More information about the awt-dev mailing list