changeset 2155:5904556f2895

Modena tweaks - added Slider with tickmarks
author mo.chicharro
date Mon, 07 Jan 2013 00:21:48 +0000
parents fb5f92a6d1f6
children f964af4aec0b
files apps/experiments/Modena/src/modena/SamplePage.java
diffstat 1 files changed, 8 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/apps/experiments/Modena/src/modena/SamplePage.java	Sun Jan 06 23:04:26 2013 +0000
+++ b/apps/experiments/Modena/src/modena/SamplePage.java	Mon Jan 07 00:21:48 2013 +0000
@@ -268,11 +268,12 @@
                 withState(new Hyperlink("F & Armed"), "focused, armed"),
                 withState(new Hyperlink("Disabled"), "disabled"));
         newDetailedSection(
-                new String[]{"Slider - H: ", "normal", "hover", "pressed", "disabled"},
-                new Slider(0, 100, 50),
-                withState(new Slider(0, 100, 50), null, ".thumb", "hover"),
-                withState(new Slider(0, 100, 50), null, ".thumb", "hover, pressed"),
-                withState(new Slider(0, 100, 50), "disabled"));
+                new String[]{"Slider - H: ", "normal", "hover", "pressed", "disabled", "tickmarks"},
+                withState(SliderBuilder.create().maxWidth(90).min(0).max(100).value(50).build(), null),
+                withState(SliderBuilder.create().maxWidth(90).min(0).max(100).value(50).build(), null, ".thumb", "hover"),
+                withState(SliderBuilder.create().maxWidth(90).min(0).max(100).value(50).build(), null, ".thumb", "hover, pressed"),
+                withState(SliderBuilder.create().maxWidth(90).min(0).max(100).value(50).build(), "disabled"),
+                SliderBuilder.create().min(0).max(100).value(50).showTickMarks(true).showTickLabels(true).build());
         newDetailedSection(
                 new String[]{"Slider - H - Focused: ", "normal", "hover", "pressed"},
                 withState(new Slider(0, 100, 50), "focused"),
@@ -282,7 +283,8 @@
                 SliderBuilder.create().min(0).max(100).value(50).orientation(Orientation.VERTICAL).build(),
                 withState(SliderBuilder.create().min(0).max(100).value(50).orientation(Orientation.VERTICAL).build(), null, ".thumb", "hover"),
                 withState(SliderBuilder.create().min(0).max(100).value(50).orientation(Orientation.VERTICAL).build(), null, ".thumb", "hover, pressed"),
-                withState(SliderBuilder.create().min(0).max(100).value(50).orientation(Orientation.VERTICAL).build(), "disabled"));
+                withState(SliderBuilder.create().min(0).max(100).value(50).orientation(Orientation.VERTICAL).build(), "disabled"),
+                SliderBuilder.create().min(0).max(100).value(50).showTickMarks(true).showTickLabels(true).orientation(Orientation.VERTICAL).build());
         newDetailedSection(
                 new String[] {"Scrollbar - H: ", "normal", "small", "big thumb"}, 
                 new ScrollBar(),