Skip to content

Commit

Permalink
Make reflection configuration platform dependent
Browse files Browse the repository at this point in the history
  • Loading branch information
atextor committed Oct 18, 2024
1 parent 5ffbd1c commit c315c88
Showing 1 changed file with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,10 @@ private void setupJava2d() {
.registerMethodForJni( "run" );
Native.forClass( "sun.java2d.windows.WindowsFlags" )
.registerFieldsForJni( "d3dEnabled", "d3dSet", "offscreenSharingEnabled", "setHighDPIAware" );
} else if ( isLinux() ) {
Native.forClass( "sun.java2d.xr.XRSurfaceData" )
.registerEverythingForReflection()
.registerFieldsForJni( "picture", "xid" );
}

Native.forClass( "sun.java2d.marlin.DMarlinRenderingEngine" )
Expand Down Expand Up @@ -146,9 +150,6 @@ private void setupJava2d() {
.registerFieldsForJni( "curIndex", "numXbands", "region" );
Native.forClass( "sun.java2d.pipe.ShapeSpanIterator" )
.registerFieldsForJni( "pData" );
Native.forClass( "sun.java2d.xr.XRSurfaceData" )
.registerEverythingForReflection()
.registerFieldsForJni( "picture", "xid" );
}

private void setupAwt() {
Expand Down

0 comments on commit c315c88

Please sign in to comment.