GitHub user mbien edited a comment on the discussion: Windows clipboard issues discussion
btw an easy way to test JDK modifications is to use `--patch-module`. A JVM agent is a bit overkill for things like this (and it adds an additional indirection layer). 1) put `java_desktop_clipboard_patch_17plus.jar` somewhere, e.g the extracted netbeans folder (jar contains only the modified classes) 2) start NB with `.\bin\netbeans.exe "-J--patch-module=java.desktop=java_desktop_clipboard_patch_17plus.jar"` I uploaded the ~jar~ (edit: outdated link removed) for convenient testing, it is slightly modified version of @xxDark [commit](https://github.com/xxDark/jdk/commit/570aeb2922ad1e4b4754fcf4fa5f122d447cc6c9). The only difference is that it will print ``` ### patched clipboard loaded ### ``` to console when the class is loaded during NB startup. Covers the from NB supported JDK range 17-24. ``` sha512sum java_desktop_clipboard_patch_17plus.jar 8acbff7fc8fb29f987bf93c6b32ed0cc5291503e4def4a36604767faf00ba4cb2ff898e49e49b5c9f63297904de681e728db385225ae11d4d32c44ce4ccace1a java_desktop_clipboard_patch_17plus.jar ``` Also: don't put random jars into your classpath, feel free to build it yourself or decompile it ;) > (Myself, I don't have an easy way to test the workaround, as I was never able > to reproduce the bug reliably.) same - all I can say is that it copies things in my test VM just like it did before ;) edit: i removed the links to the test jars since with the release of NB 26 they are not relevant anymore. GitHub link: https://github.com/apache/netbeans/discussions/7051#discussioncomment-12319448 ---- This is an automatically sent email for notifications@netbeans.apache.org. To unsubscribe, please send an email to: notifications-unsubscr...@netbeans.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@netbeans.apache.org For additional commands, e-mail: notifications-h...@netbeans.apache.org For further information about the NetBeans mailing lists, visit: https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists