mirror of
https://github.com/alinanorakari/Pebble-Watchface-Squared-1.0.git
synced 2026-01-15 09:25:22 +01:00
Flag for leading zeros
Added a boolean to switch on or off the "cyclers" that normally replace leading zeros in hour, day and month.
This commit is contained in:
BIN
squared_screen_eu.png
Normal file
BIN
squared_screen_eu.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
squared_screen_eu_zero.png
Normal file
BIN
squared_screen_eu_zero.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
squared_screen_zero.png
Normal file
BIN
squared_screen_zero.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 1.2 KiB |
BIN
src/.DS_Store
vendored
Normal file
BIN
src/.DS_Store
vendored
Normal file
Binary file not shown.
@@ -11,7 +11,8 @@ PBL_APP_INFO(MY_UUID,
|
||||
|
||||
Window window;
|
||||
|
||||
#define US_DATE false // true == MM/DD, false == DD/MM
|
||||
#define US_DATE true // true == MM/DD, false == DD/MM
|
||||
#define NO_ZERO true // false == replaces leading Zero for hour, day, month with a "cycler"
|
||||
#define TILE_SIZE 10
|
||||
#define NUMSLOTS 8
|
||||
#define SPACING_X TILE_SIZE
|
||||
@@ -251,6 +252,7 @@ void handle_tick(AppContextRef ctx, PebbleTickEvent *evt) {
|
||||
slot[7].curDigit = mo%10;
|
||||
}
|
||||
|
||||
if (NO_ZERO) {
|
||||
if (slot[0].curDigit == 0) {
|
||||
slot[0].curDigit = 10;
|
||||
if (slot[0].prevDigit == 10) {
|
||||
@@ -269,6 +271,7 @@ void handle_tick(AppContextRef ctx, PebbleTickEvent *evt) {
|
||||
slot[6].curDigit++;
|
||||
}
|
||||
}
|
||||
}
|
||||
animation_schedule(&anim);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user