On Wed, 13 Mar 2024 19:40:16 GMT, Alexander Zuev <kiz...@openjdk.org> wrote:
>> test/jdk/javax/swing/JDesktopPane/bug4773378.java line 99: >> >>> 97: bug4773378.this.wait(); >>> 98: } >>> 99: } >> >> Suggestion: >> >> frameActivated.await(); >> >> >> Using `CountDownLatch` is so much cleaner. > > You like your countdown latches :) Ok, i will re-write this test with CDL. Because 1 line of code replaces 4 lines of code and communicates what's happening much clearer than a synchronized block with a flag. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/18259#discussion_r1524493581