classic-lite

Minimalist rewrite of Łukasz Zalewski's "classic" pebble watchface
git clone https://git.instinctive.eu/classic-lite.git
Log | Files | Refs | README | LICENSE

commit c6f92367d3701c4cb35dca4528633d6bc94ff143
parent 9bb74ecd5e1e708a17505ee2dd1d5d107ed9d1c4
Author: Natasha Kerensikova <natacha@instinctive.eu>
Date:   Sat,  5 Dec 2015 18:04:27 +0000

Fix color initialization overwriting values read from persistent storage
Diffstat:
Msrc/classic-lite.c | 20++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/classic-lite.c b/src/classic-lite.c @@ -603,16 +603,6 @@ init(void) { time_t current_time = time(0); tm_now = *localtime(&current_time); - bluetooth_connected = connection_service_peek_pebble_app_connection(); - current_battery = battery_state_service_peek().charge_percent; - read_config(); - - window = window_create(); - window_set_window_handlers(window, (WindowHandlers) { - .load = window_load, - .unload = window_unload, - }); - background_color = GColorWhite; bluetooth_color = GColorBlack; hand_color = GColorBlack; @@ -628,6 +618,16 @@ init(void) { inner_rectangle_color = GColorLightGray; #endif + bluetooth_connected = connection_service_peek_pebble_app_connection(); + current_battery = battery_state_service_peek().charge_percent; + read_config(); + + window = window_create(); + window_set_window_handlers(window, (WindowHandlers) { + .load = window_load, + .unload = window_unload, + }); + bluetooth_frame = gpath_create(&bluetooth_frame_points); bluetooth_logo = gpath_create(&bluetooth_logo_points); hour_hand_path = gpath_create(&hour_hand_path_points);