RFR: 8238674: WindowOwnedByEmbeddedFrameTest: sun.java2d.opengl.CGLLayer cannot be cast to sun.java2d.metal.MTLLayer

Ajit Ghaisas aghaisas at openjdk.java.net
Mon Mar 9 09:26:25 UTC 2020

Issue :

The jtreg test java/awt/Window/WindowOwnedByEmbeddedFrameTest/WindowOwnedByEmbeddedFrameTest.java fails with -Dsun.java2d.metal=true

Root cause :
class CPlatformEmbeddedFrame has a windowLayer member & it's usage. It is hard-coded to CGLLayer. 

Fix : 
Added check whether Metal is enabled, intantiated windowLayer appropriately to either CGLLayer or MTLLayer.


 - c28bfb17: WindowOwnedByEmbeddedFrameTest fails with Metal

Changes: https://git.openjdk.java.net/lanai/pull/3/files
 Webrev: https://webrevs.openjdk.java.net/lanai/3/webrev.00
  Issue: https://bugs.openjdk.java.net/browse/JDK-8238674
  Stats: 31 lines in 1 file changed: 24 ins; 0 del; 7 mod
  Patch: https://git.openjdk.java.net/lanai/pull/3.diff
  Fetch: git fetch https://git.openjdk.java.net/lanai pull/3/head:pull/3

PR: https://git.openjdk.java.net/lanai/pull/3

More information about the lanai-dev mailing list