Added new improvements
This commit is contained in:
parent
8775f573bb
commit
91cc332912
@ -528,6 +528,11 @@ public class TimeCalcManager {
|
||||
window.setSize(520 + 20 + 100,
|
||||
exitButton.getY() + 3 * exitButton.getHeight() + MARGIN);
|
||||
while (true) {
|
||||
Visibility visibility = Visibility
|
||||
.valueOf(timeCalcApp.visibilityProperty.getValue());
|
||||
if(timeCalcConfiguration.visibilityOnlyGreyOrNoneEnabledProperty.isEnabled() && visibility.isColored() ){
|
||||
timeCalcApp.visibilityProperty.setValue(Visibility.GRAY.name());
|
||||
}
|
||||
//time.writeString();
|
||||
if (stopBeforeEnd) {
|
||||
window.setVisible(false);
|
||||
@ -535,8 +540,7 @@ public class TimeCalcManager {
|
||||
break;
|
||||
}
|
||||
|
||||
Visibility visibility = Visibility
|
||||
.valueOf(timeCalcApp.visibilityProperty.getValue());
|
||||
|
||||
componentRegistry.setVisible(visibility.isNotNone());
|
||||
if (!visibility.isStronglyColored() || visibility.isGray()) {
|
||||
configButton.setBackground(BG);
|
||||
|
@ -21,6 +21,9 @@ public enum Visibility {
|
||||
return this == WEAKLY_COLORED;
|
||||
}
|
||||
|
||||
public boolean isColored() {
|
||||
return isStronglyColored() || isWeaklyColored();
|
||||
}
|
||||
public boolean isGray() {
|
||||
return this == GRAY;
|
||||
}
|
||||
|
@ -24,13 +24,13 @@ public class TimeCalcButton extends JButton {
|
||||
|
||||
public TimeCalcButton(String label) {
|
||||
super(label);
|
||||
new Timer(100, e -> repaint()).start();
|
||||
}
|
||||
|
||||
public void setBounds(int x, int y) {
|
||||
setBounds(x, y, BUTTON_WIDTH, BUTTON_HEIGHT);
|
||||
this.originalBackground = getBackground();
|
||||
this.originalForeground = getForeground();
|
||||
new Timer(100, e -> repaint()).start();
|
||||
}
|
||||
|
||||
public void setOriginalBackground() {
|
||||
|
@ -1,10 +1,10 @@
|
||||
clock.hands.long=true
|
||||
clock.hands.minute.enabled=false
|
||||
clock.hands.minute.enabled=true
|
||||
clock.hands.second.enabled=true
|
||||
clock.hands.millisecond.enabled=false
|
||||
battery.waves.enabled=true
|
||||
default-visibility=STRONGLY_COLORED
|
||||
visibility.only-grey-or-none.enabled=true
|
||||
visibility.only-grey-or-none.enabled=false
|
||||
jokes.enabled=true
|
||||
commands.enabled=true
|
||||
toasts.enabled=true
|
||||
|
Loading…
x
Reference in New Issue
Block a user