ConfigWindow V
This commit is contained in:
parent
e1dfb42149
commit
f1dadc033f
@ -56,6 +56,7 @@ public class TimeCalcConfiguration {
|
||||
visibilityDefaultProperty,
|
||||
visibilitySupportedColoredProperty,
|
||||
clockHandsLongVisibleProperty,
|
||||
clockHandsMinuteVisibleProperty,
|
||||
clockHandsSecondVisibleProperty,
|
||||
clockHandsMillisecondVisibleProperty,
|
||||
batteryWavesVisibleProperty,
|
||||
@ -95,6 +96,10 @@ public class TimeCalcConfiguration {
|
||||
throw new TimeCalcException("Unsupported Property class: " + p.getClass().getName());
|
||||
|
||||
}
|
||||
for(Property p:allProperties) {
|
||||
System.out.println(p.getName() + "=" + p.getValue());
|
||||
}
|
||||
System.out.println("clockHandsMinuteVisibleProperty=" + clockHandsMinuteVisibleProperty.isEnabled());
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -31,15 +31,12 @@ public class TimeCalcKeyAdapter extends KeyAdapter {
|
||||
}
|
||||
|
||||
public void keyPressed(KeyEvent e) {
|
||||
System.out.println("Key was pressed: " + e);
|
||||
boolean onlyGreyOrNone =
|
||||
timeCalcConfiguration.visibilitySupportedColoredProperty
|
||||
.isEnabled();
|
||||
Visibility visibility = Visibility
|
||||
.valueOf(timeCalcApp.visibilityProperty.getValue());
|
||||
System.out.println("visibility=" + visibility);
|
||||
if (e.getKeyCode() == KeyEvent.VK_UP) {
|
||||
System.out.println("Key UP was pressed: " + e);
|
||||
timeCalcApp.visibilityProperty
|
||||
.setValue(onlyGreyOrNone ? Visibility.GRAY.name() :
|
||||
Visibility.STRONGLY_COLORED.name());
|
||||
@ -84,7 +81,6 @@ public class TimeCalcKeyAdapter extends KeyAdapter {
|
||||
}
|
||||
}
|
||||
if (e.getKeyCode() == KeyEvent.VK_V) {
|
||||
System.out.println("Key V was pressed: " + e);
|
||||
if (visibility.isNone()) {
|
||||
timeCalcApp.visibilityProperty
|
||||
.setValue(onlyGreyOrNone ? Visibility.GRAY.name() :
|
||||
|
@ -289,27 +289,8 @@ public class MainWindow extends TimeCalcWindow{
|
||||
add(monthBattery);
|
||||
|
||||
ComponentRegistry<Component> componentRegistry = new ComponentRegistry();
|
||||
// componentRegistry.addAll(
|
||||
// walkingHumanProgressAsciiArt,
|
||||
// progressSquare,
|
||||
// progressCircle,
|
||||
// analogClock,
|
||||
// dayBattery,
|
||||
// weekBattery,
|
||||
// monthBattery,
|
||||
// hourBattery,
|
||||
// configButton,
|
||||
// workDaysButton,
|
||||
// activitiesButton,
|
||||
// restartButton,
|
||||
// exitButton,
|
||||
// helpButton,
|
||||
// focusButton,
|
||||
// jokeButton,
|
||||
// commandButton
|
||||
// );
|
||||
componentRegistry.addAll(this.getContentPane().getComponents());
|
||||
componentRegistry.getSet().stream().forEach(c-> System.out.println("Found component: " + c));
|
||||
|
||||
ComponentRegistry<TimeCalcButton> buttonRegistry = new ComponentRegistry();
|
||||
componentRegistry.getSet().stream().filter(c-> c instanceof TimeCalcButton).forEach(c->
|
||||
buttonRegistry.add((TimeCalcButton)c));
|
||||
|
@ -14,18 +14,20 @@ notifications.visible=true
|
||||
smileys.colored=false
|
||||
|
||||
#todo
|
||||
visibility.smileys.enabled=true
|
||||
visibility.battery.smileys.enabled=true
|
||||
visibility.progress.square.smileys.enabled=true
|
||||
visibility.progress.circle.smileys.enabled=true
|
||||
visibility.battery.charging-unicode-character.enabled=true
|
||||
logs.detailed=false
|
||||
smileys.visible=true
|
||||
battery.smileys.visible=true
|
||||
square.smileys.visible=true
|
||||
circle.smileys.visible=true
|
||||
battery.charging-unicode-character.visible=true
|
||||
battery.percent-precision.count-of-decimal-points=5
|
||||
visibility.battery.label.finished-from-total.enabled=true
|
||||
visibility.widgets.clock.enabled=true
|
||||
visibility.widgets.progress-square.enabled=true
|
||||
visibility.widgets.progress-circle.enabled=true
|
||||
visibility.widgets.walking-human.enabled=true
|
||||
visibility.widgets.battery.hour.enabled=true
|
||||
visibility.widgets.battery.day.enabled=true
|
||||
visibility.widgets.battery.week.enabled=true
|
||||
visibility.widgets.battery.month.enabled=true
|
||||
battery.label.finished-from-total.visible=true
|
||||
widgets.clock.visible=true
|
||||
square.visible=true
|
||||
circle.visible=true
|
||||
walking-human.visible=true
|
||||
battery.visible=true
|
||||
battery.hour.visible=true
|
||||
battery.day.visible=true
|
||||
battery.week.visible=true
|
||||
battery.month.visible=true
|
||||
|
@ -14,18 +14,21 @@ notifications.visible=true
|
||||
smileys.colored=false
|
||||
|
||||
#todo
|
||||
visibility.smileys.enabled=true
|
||||
visibility.battery.smileys.enabled=true
|
||||
visibility.progress.square.smileys.enabled=true
|
||||
visibility.progress.circle.smileys.enabled=true
|
||||
visibility.battery.charging-unicode-character.enabled=true
|
||||
logs.detailed=false
|
||||
smileys.visible=true
|
||||
battery.smileys.visible=true
|
||||
square.smileys.visible=true
|
||||
circle.smileys.visible=true
|
||||
battery.charging-unicode-character.visible=true
|
||||
battery.percent-precision.count-of-decimal-points=5
|
||||
visibility.battery.label.finished-from-total.enabled=true
|
||||
visibility.widgets.clock.enabled=true
|
||||
visibility.widgets.progress-square.enabled=true
|
||||
visibility.widgets.progress-circle.enabled=true
|
||||
visibility.widgets.walking-human.enabled=true
|
||||
visibility.widgets.battery.hour.enabled=true
|
||||
visibility.widgets.battery.day.enabled=true
|
||||
visibility.widgets.battery.week.enabled=true
|
||||
visibility.widgets.battery.month.enabled=true
|
||||
battery.label.finished-from-total.visible=true
|
||||
widgets.clock.visible=true
|
||||
square.visible=true
|
||||
circle.visible=true
|
||||
walking-human.visible=true
|
||||
battery.visible=true
|
||||
battery.hour.visible=true
|
||||
battery.day.visible=true
|
||||
battery.week.visible=true
|
||||
battery.month.visible=true
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user