On Wed, 5 May 2021 02:34:52 GMT, Sergey Bylokhov <s...@openjdk.org> wrote:
>> Jayathirth D V has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Move peer and getters to CFLayer > > src/java.desktop/macosx/classes/sun/java2d/opengl/CGLLayer.java line 60: > >> 58: return ptr; >> 59: } >> 60: > > dispose and getBounds(probably some others) seems to have the same > implementation in both classes? In dispose() we call validate which internally calls corresponding RenderQueue's of OpenGL/Metal, thats why it is not moved to CFLayer. For other getters since initialization of peer was happening in individual subclasses(which in turn calls OpenGL/Metal native initialization) i had kept getters also in subclasses, but we can move getters to CFLayer. I have updated the PR. ------------- PR: https://git.openjdk.java.net/jdk/pull/3851