OpenJDK / portola / portola
changeset 24544:c0133e7c7162
8041917: unexcepted behavior of LineBorder while using Boolean variable true
Reviewed-by: alexsch, serb
author | malenkov |
---|---|
date | Wed, 30 Apr 2014 19:28:05 +0400 |
parents | 90f9cb8175ef |
children | 5f998bcc934e |
files | jdk/src/share/classes/javax/swing/border/LineBorder.java jdk/test/javax/swing/border/Test4252164.java |
diffstat | 2 files changed, 3 insertions(+), 3 deletions(-) [+] |
line wrap: on
line diff
--- a/jdk/src/share/classes/javax/swing/border/LineBorder.java Wed Apr 30 11:29:29 2014 +0200 +++ b/jdk/src/share/classes/javax/swing/border/LineBorder.java Wed Apr 30 19:28:05 2014 +0400 @@ -134,8 +134,8 @@ int offs = this.thickness; int size = offs + offs; if (this.roundedCorners) { - int arc = offs + size; - outer = new RoundRectangle2D.Float(x, y, width, height, arc, arc); + float arc = .2f * offs; + outer = new RoundRectangle2D.Float(x, y, width, height, offs, offs); inner = new RoundRectangle2D.Float(x + offs, y + offs, width - size, height - size, arc, arc); } else {
--- a/jdk/test/javax/swing/border/Test4252164.java Wed Apr 30 11:29:29 2014 +0200 +++ b/jdk/test/javax/swing/border/Test4252164.java Wed Apr 30 19:28:05 2014 +0400 @@ -23,7 +23,7 @@ /* * @test - * @bug 4252164 + * @bug 4252164 8041917 * @summary Tests rounded LineBorder for components * @author Sergey Malenkov * @run applet/manual=yesno Test4252164.html