summaryrefslogtreecommitdiff
path: root/quantum/rgblight/rgblight.c
diff options
context:
space:
mode:
Diffstat (limited to 'quantum/rgblight/rgblight.c')
-rw-r--r--quantum/rgblight/rgblight.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/quantum/rgblight/rgblight.c b/quantum/rgblight/rgblight.c
index 19d80e0097..02188df95b 100644
--- a/quantum/rgblight/rgblight.c
+++ b/quantum/rgblight/rgblight.c
@@ -21,6 +21,7 @@
#include "rgblight.h"
#include "color.h"
#include "debug.h"
+#include "util.h"
#include "led_tables.h"
#include <lib/lib8tion/lib8tion.h>
#ifdef EEPROM_ENABLE
@@ -30,13 +31,6 @@
# include "velocikey.h"
#endif
-#ifndef MIN
-# define MIN(a, b) (((a) < (b)) ? (a) : (b))
-#endif
-#ifndef MAX
-# define MAX(a, b) (((a) > (b)) ? (a) : (b))
-#endif
-
#ifdef RGBLIGHT_SPLIT
/* for split keyboard */
# define RGBLIGHT_SPLIT_SET_CHANGE_MODE rgblight_status.change_flags |= RGBLIGHT_STATUS_CHANGE_MODE
@@ -422,6 +416,10 @@ void rgblight_disable_noeeprom(void) {
rgblight_set();
}
+void rgblight_enabled_noeeprom(bool state) {
+ state ? rgblight_enable_noeeprom() : rgblight_disable_noeeprom();
+}
+
bool rgblight_is_enabled(void) {
return rgblight_config.enable;
}