diff options
-rw-r--r-- | apps/plugins/lib/helper.c | 16 |
1 files changed, 0 insertions, 16 deletions
diff --git a/apps/plugins/lib/helper.c b/apps/plugins/lib/helper.c index c70d8264a5..e35e43a40a 100644 --- a/apps/plugins/lib/helper.c +++ b/apps/plugins/lib/helper.c | |||
@@ -25,8 +25,6 @@ | |||
25 | /* Force the backlight on */ | 25 | /* Force the backlight on */ |
26 | void backlight_force_on(void) | 26 | void backlight_force_on(void) |
27 | { | 27 | { |
28 | if(!rb) | ||
29 | return; | ||
30 | if (rb->global_settings->backlight_timeout > 0) | 28 | if (rb->global_settings->backlight_timeout > 0) |
31 | rb->backlight_set_timeout(0); | 29 | rb->backlight_set_timeout(0); |
32 | #if CONFIG_CHARGING | 30 | #if CONFIG_CHARGING |
@@ -38,8 +36,6 @@ void backlight_force_on(void) | |||
38 | /* Reset backlight operation to its settings */ | 36 | /* Reset backlight operation to its settings */ |
39 | void backlight_use_settings(void) | 37 | void backlight_use_settings(void) |
40 | { | 38 | { |
41 | if (!rb) | ||
42 | return; | ||
43 | rb->backlight_set_timeout(rb->global_settings->backlight_timeout); | 39 | rb->backlight_set_timeout(rb->global_settings->backlight_timeout); |
44 | #if CONFIG_CHARGING | 40 | #if CONFIG_CHARGING |
45 | rb->backlight_set_timeout_plugged(rb->global_settings-> | 41 | rb->backlight_set_timeout_plugged(rb->global_settings-> |
@@ -51,8 +47,6 @@ void backlight_use_settings(void) | |||
51 | /* Force the backlight on */ | 47 | /* Force the backlight on */ |
52 | void remote_backlight_force_on(void) | 48 | void remote_backlight_force_on(void) |
53 | { | 49 | { |
54 | if (!rb) | ||
55 | return; | ||
56 | if (rb->global_settings->remote_backlight_timeout > 0) | 50 | if (rb->global_settings->remote_backlight_timeout > 0) |
57 | rb->remote_backlight_set_timeout(0); | 51 | rb->remote_backlight_set_timeout(0); |
58 | #if CONFIG_CHARGING | 52 | #if CONFIG_CHARGING |
@@ -64,8 +58,6 @@ void remote_backlight_force_on(void) | |||
64 | /* Reset backlight operation to its settings */ | 58 | /* Reset backlight operation to its settings */ |
65 | void remote_backlight_use_settings(void) | 59 | void remote_backlight_use_settings(void) |
66 | { | 60 | { |
67 | if (!rb) | ||
68 | return; | ||
69 | rb->remote_backlight_set_timeout(rb->global_settings-> | 61 | rb->remote_backlight_set_timeout(rb->global_settings-> |
70 | remote_backlight_timeout); | 62 | remote_backlight_timeout); |
71 | #if CONFIG_CHARGING | 63 | #if CONFIG_CHARGING |
@@ -79,8 +71,6 @@ void remote_backlight_use_settings(void) | |||
79 | /* Force the buttonlight on */ | 71 | /* Force the buttonlight on */ |
80 | void buttonlight_force_on(void) | 72 | void buttonlight_force_on(void) |
81 | { | 73 | { |
82 | if (!rb) | ||
83 | return; | ||
84 | if (rb->global_settings->buttonlight_timeout > 0) | 74 | if (rb->global_settings->buttonlight_timeout > 0) |
85 | rb->buttonlight_set_timeout(0); | 75 | rb->buttonlight_set_timeout(0); |
86 | } | 76 | } |
@@ -88,8 +78,6 @@ void buttonlight_force_on(void) | |||
88 | /* Reset buttonlight operation to its settings */ | 78 | /* Reset buttonlight operation to its settings */ |
89 | void buttonlight_use_settings(void) | 79 | void buttonlight_use_settings(void) |
90 | { | 80 | { |
91 | if (!rb) | ||
92 | return; | ||
93 | rb->buttonlight_set_timeout(rb->global_settings->buttonlight_timeout); | 81 | rb->buttonlight_set_timeout(rb->global_settings->buttonlight_timeout); |
94 | } | 82 | } |
95 | #endif /* HAVE_BUTTON_LIGHT */ | 83 | #endif /* HAVE_BUTTON_LIGHT */ |
@@ -97,15 +85,11 @@ void buttonlight_use_settings(void) | |||
97 | #ifdef HAVE_BACKLIGHT_BRIGHTNESS | 85 | #ifdef HAVE_BACKLIGHT_BRIGHTNESS |
98 | void backlight_brightness_set(int brightness) | 86 | void backlight_brightness_set(int brightness) |
99 | { | 87 | { |
100 | if (!rb) | ||
101 | return; | ||
102 | rb->backlight_set_brightness(brightness); | 88 | rb->backlight_set_brightness(brightness); |
103 | } | 89 | } |
104 | 90 | ||
105 | void backlight_brightness_use_setting(void) | 91 | void backlight_brightness_use_setting(void) |
106 | { | 92 | { |
107 | if (!rb) | ||
108 | return; | ||
109 | rb->backlight_set_brightness(rb->global_settings->brightness); | 93 | rb->backlight_set_brightness(rb->global_settings->brightness); |
110 | } | 94 | } |
111 | #endif /* HAVE_BACKLIGHT_BRIGHTNESS */ | 95 | #endif /* HAVE_BACKLIGHT_BRIGHTNESS */ |