Clearly indicate when falling back to last played
This commit is contained in:
@@ -88,7 +88,13 @@ static void inbox_received_handler(DictionaryIterator *iter, void *context) {
|
|||||||
Tuple *watched_tuple = dict_find(iter, MESSAGE_KEY_PKJS_LAST_WATCHED);
|
Tuple *watched_tuple = dict_find(iter, MESSAGE_KEY_PKJS_LAST_WATCHED);
|
||||||
if (watched_tuple) {
|
if (watched_tuple) {
|
||||||
// APP_LOG(APP_LOG_LEVEL_INFO, "Received PKJS_LAST_WATCHED, displaying...");
|
// APP_LOG(APP_LOG_LEVEL_INFO, "Received PKJS_LAST_WATCHED, displaying...");
|
||||||
|
if (s_sleep_session_found) {
|
||||||
text_layer_set_text(s_last_watched_layer, watched_tuple->value->cstring);
|
text_layer_set_text(s_last_watched_layer, watched_tuple->value->cstring);
|
||||||
|
} else {
|
||||||
|
static char last_watched_buffer[1024];
|
||||||
|
snprintf(last_watched_buffer, sizeof(last_watched_buffer), "Last item played:\n%s", watched_tuple->value->cstring);
|
||||||
|
text_layer_set_text(s_last_watched_layer, last_watched_buffer);
|
||||||
|
}
|
||||||
#if PBL_DISPLAY_WIDTH >= 200
|
#if PBL_DISPLAY_WIDTH >= 200
|
||||||
PropertyAnimation *sleep_bar_prop = property_animation_create_layer_frame(s_sleep_bar_layer, &s_sleep_bar_start, &GRect(0, -PBL_DISPLAY_HEIGHT + PBL_IF_ROUND_ELSE(53, 31), PBL_DISPLAY_WIDTH, PBL_DISPLAY_HEIGHT));
|
PropertyAnimation *sleep_bar_prop = property_animation_create_layer_frame(s_sleep_bar_layer, &s_sleep_bar_start, &GRect(0, -PBL_DISPLAY_HEIGHT + PBL_IF_ROUND_ELSE(53, 31), PBL_DISPLAY_WIDTH, PBL_DISPLAY_HEIGHT));
|
||||||
#else
|
#else
|
||||||
|
|||||||
Reference in New Issue
Block a user