1
0
Fork 0
forked from len0rd/rockbox

plugins: clock: simplify settings

- Use system time format and remove separate setting
- Hide timer until started & eliminate setting for it
- Simplify menu, reorder settings, keep theme enabled
- Make dialog for resetting settings more consistent
  with other reset dialogs

Change-Id: I0fd38612b0592cd5a650c8985f377acc70a48eb7
This commit is contained in:
Christian Soffke 2025-06-07 20:58:09 +02:00
parent ab161a3d89
commit 8d4efb6cf2
6 changed files with 60 additions and 95 deletions

View file

@ -145,13 +145,16 @@ enum plugin_status plugin_start(const void* parameter){
redraw=true;/* we'll set it to false afterwards if there was no action */
switch (button){
case ACTION_COUNTER_TOGGLE: /* start/stop counter */
if(clock_settings.general.show_counter)
counter_toggle(&counter);
show_counter = true;
counter_toggle(&counter);
break;
case ACTION_COUNTER_RESET: /* reset counter */
if(clock_settings.general.show_counter)
if(show_counter)
{
counter_reset(&counter);
show_counter = false;
}
break;
case ACTION_MODE_NEXT_REPEAT:
@ -179,7 +182,11 @@ enum plugin_status plugin_start(const void* parameter){
#endif
case ACTION_MENU:
clock_draw_restore_colors();
FOR_NB_SCREENS(i)
rb->viewportmanager_theme_enable(i, true, NULL);
exit_clock=main_menu();
FOR_NB_SCREENS(i)
rb->viewportmanager_theme_undo(i, false);
break;
default:
exit_on_usb(button);