<Swing Dev> [12] RFR JDK-8203904:javax/swing/JSplitPane/4816114/bug4816114.java: The divider location is wrong

Krishna Addepalli krishna.addepalli at oracle.com
Tue Jul 24 16:40:04 UTC 2018


Hi Prasanta,

The fix looks ok, but for disposing the frame, instead of repeating the same line twice, I would suggest to embed it into try ... finally clause.
Also, since "doTest" can technically throw exceptions, all those calls should be included in the try block as well.

Thanks,
Krishna

-----Original Message-----
From: Prasanta Sadhukhan 
Sent: Tuesday, July 24, 2018 3:44 PM
To: swing-dev at openjdk.java.net
Subject: <Swing Dev> [12] RFR JDK-8203904:javax/swing/JSplitPane/4816114/bug4816114.java: The divider location is wrong

Hi All,

Please review a fix for an test problem where it is seen that the test passes on windows 7 but fails on windows 10 citing the JSplitPane divider location is wrong.
This is because in windows 10, the frame border width/height is different compared to windows 7 so splitpane is moved accordingly in the frame.

Proposed fix is to undecorate the frame so that border is not considered and splitpane position is considered from top/left of the frame itself.
webrev: http://cr.openjdk.java.net/~psadhukhan/8203904/webrev.0/
Bug: https://bugs.openjdk.java.net/browse/JDK-8203904

Additionally, the test frame is also disposed which was not done earlier.
The test now passes in windows 7, windows 10, ubuntu 18, mac 10.13.

Regards
Prasanta





More information about the swing-dev mailing list