Skip to content

Commit 79d78a4

Browse files
test: update, should have been testing different method from upstream. style: uncommented SmallBar logic
1 parent daeb4dc commit 79d78a4

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

app/display/representation-javafx/src/main/java/org/csstudio/display/builder/representation/javafx/widgets/ProgressBarRepresentation.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -175,8 +175,8 @@ public void updateChanges()
175175
// Default 'inset' of .bar uses 7 pixels.
176176
// A widget sized 15 has 8 pixels left for the bar.
177177
// Select leaner style where .bar uses full size.
178-
// Styles.update(jfx_node, "SmallBar",
179-
// Math.min(width, height) <= 15);
178+
Styles.update(jfx_node, "SmallBar",
179+
Math.min(width, height) <= 15);
180180

181181
// Could clear style and use setBackground(),
182182
// but result is very plain.

app/display/representation-javafx/src/test/java/org/csstudio/display/builder/representation/javafx/JFXUtilTest.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,8 @@ public void testRGBWithAlpha()
4646
{
4747
// NOTE that the actual decimal value for transparency would have been 0.019607844, however it needs
4848
// to be formatted to two decimal places
49-
assertThat(JFXUtil.webRGB(JFXUtil.convert(new WidgetColor(15, 255, 0, 5))), equalTo("rgba(15,255,0,0.02)"));
50-
assertThat(JFXUtil.webRGB(JFXUtil.convert(new WidgetColor(0, 16, 255))), equalTo("#0010FF"));
49+
assertThat(JFXUtil.webRgbOrHex(new WidgetColor(15, 255, 0, 5)), equalTo("rgba(15,255,0,0.02)"));
50+
assertThat(JFXUtil.webRgbOrHex(new WidgetColor(0, 16, 255)), equalTo("#0010FF"));
5151
}
5252

5353
@Test

0 commit comments

Comments
 (0)