RFR: 8305578: X11GraphicsDevice.pGetBounds() is slow in remote X11 sessions [v3]

Maxim Kartashev mkartashev at openjdk.org
Mon Apr 17 08:58:41 UTC 2023


On Fri, 14 Apr 2023 19:56:50 GMT, Sergey Bylokhov <serb at openjdk.org> wrote:

>> II suggest to check how it works on win/mac, does we trigger displayChanged in that case?
>
> Even if we skip displayChanged, it is better to inject the field to the GC, and update it on demand, in as similar way the displayChanged is implemented.

> II suggest to check how it works on win/mac, does we trigger displayChanged in that case?

I doubt it: see comments in [CGraphicsDevice.getScreenInsets()](https://github.com/openjdk/jdk/blob/2a062f165491d599eb0dcfb6050eb9186ae31b71/src/java.desktop/macosx/classes/sun/awt/CGraphicsDevice.java#L185)

        // the insets are queried synchronously and are not cached
        // since there are no Quartz or Cocoa means to receive notifications
        // on insets changes (e.g. when the Dock is resized):
        // the existing CGDisplayReconfigurationCallBack is not notified
        // as well as the NSApplicationDidChangeScreenParametersNotification
        // is fired on the Dock location changes only

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/13346#discussion_r1168385232



More information about the client-libs-dev mailing list