chronowid 0.03
parent
1017090cbe
commit
ae738e9d99
|
|
@ -1,2 +1,3 @@
|
||||||
0.01: New widget and app!
|
0.01: New widget and app!
|
||||||
0.02: Setting to reset values, timer buzzes at 00:00 and not later (see readme)
|
0.02: Setting to reset values, timer buzzes at 00:00 and not later (see readme)
|
||||||
|
0.03: Display only minutes:seconds when less than 1 hour left
|
||||||
|
|
@ -58,13 +58,13 @@
|
||||||
}
|
}
|
||||||
g.reset();
|
g.reset();
|
||||||
if (diff >= 0) {
|
if (diff >= 0) {
|
||||||
if (diff < 600000) { //less than 1 hour left
|
if (diff < 3600000) { //less than 1 hour left
|
||||||
width = 58;
|
width = 58;
|
||||||
g.clearRect(this.x,this.y,this.x+width,this.y+height);
|
g.clearRect(this.x,this.y,this.x+width,this.y+height);
|
||||||
g.setFont("6x8", 2);
|
g.setFont("6x8", 2);
|
||||||
g.drawString(getTime(diff).substring(3), this.x+1, this.y+5); //remove hour part 00:00:00 -> 00:00
|
g.drawString(getTime(diff).substring(3), this.x+1, this.y+5); //remove hour part 00:00:00 -> 00:00
|
||||||
}
|
}
|
||||||
if (diff >= 600000) { //one hour or more left
|
if (diff >= 3600000) { //one hour or more left
|
||||||
width = 48;
|
width = 48;
|
||||||
g.clearRect(this.x,this.y,this.x+width,this.y+height);
|
g.clearRect(this.x,this.y,this.x+width,this.y+height);
|
||||||
g.setFont("6x8", 1);
|
g.setFont("6x8", 1);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue