RFR: 8274932: Render scales in EmbeddedWindow are not properly updated

Andy Goryachev angorya at openjdk.org
Fri Jul 7 16:56:05 UTC 2023


On Fri, 7 Jul 2023 16:42:58 GMT, Prasanta Sadhukhan <psadhukhan at openjdk.org> wrote:

> You need to run with this change

Does not help.

I think the problem is that FX stage is being manipulated from the EDT, see the comment  in JFXPanel:607 and the FX stage access on JFXPanel:640.  

You probably need to wrap the following code in Platform.runLater(), though I can't tell if sendResizeEventToFX(); should be in the EDT or FX app thread:


            if (stage != null) {
               stage.setRenderScaleX(scaleFactorX);
               stage.setRenderScaleY(scaleFactorY);
            }
            sendResizeEventToFX();

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

PR Comment: https://git.openjdk.org/jfx/pull/1171#issuecomment-1625685563


More information about the openjfx-dev mailing list