Bladeren bron

Revert "Merge nightstand_clock from https://github.com/xMasterX/all-the-plugins"

This reverts commit 7c4188618af1f238e8a2ea384dd1032ae7097881, reversing
changes made to b80db46749343aedbf01babea41ee6055f174836.
WillyJL 7 maanden geleden
bovenliggende
commit
f498b279e4
1 gewijzigde bestanden met toevoegingen van 1 en 8 verwijderingen
  1. 1 8
      nightstand_clock/clock_app.c

+ 1 - 8
nightstand_clock/clock_app.c

@@ -122,7 +122,7 @@ static void clock_render_callback(Canvas* const canvas, void* ctx) {
     //canvas_set_color(canvas, ColorBlack);
 
     //avoids a bug with the brightness being reverted after the backlight-off period
-    //set_backlight_brightness((float)(brightness / 100.f));
+    set_backlight_brightness((float)(brightness / 100.f));
 
     if(dspBrightnessBarFrames > 0) {
         elements_progress_bar_vertical(canvas, 119, 1, 62, (float)(brightness / 100.f));
@@ -315,10 +315,6 @@ int32_t clock_app(void* p) {
     float tmpBrightness = notif->settings.display_brightness;
     brightness = tmpBrightness * 100; // Keep current brightness by default
 
-    //save current user settings to tmp, disable backlight delay and force dislay always on
-    uint32_t tmp_display_off_delay_ms = notif->settings.display_off_delay_ms;
-    notif->settings.display_off_delay_ms = 0;
-
     notification_message(notif, &sequence_display_backlight_enforce_on);
     notification_message(notif, &led_off);
 
@@ -398,9 +394,6 @@ int32_t clock_app(void* p) {
     furi_mutex_free(plugin_state->mutex);
     free(plugin_state);
 
-    //restore display backlight timer settings;
-    notif->settings.display_off_delay_ms = tmp_display_off_delay_ms;
-
     set_backlight_brightness(tmpBrightness);
     notification_message(notif, &sequence_display_backlight_enforce_auto);
     notification_message(notif, &led_reset);