diff options
author | David Dai <newtonapple@gmail.com> | 2018-12-31 08:42:58 -0800 |
---|---|---|
committer | MechMerlin <30334081+mechmerlin@users.noreply.github.com> | 2018-12-31 08:42:58 -0800 |
commit | b7688590b8a252f7497e3f78d569b98ae62ab177 (patch) | |
tree | 5b6eca2321798a1116ab251da0d1029d01eb07b2 | |
parent | 0c0e208a36300660f3d568d52ae3155becf92893 (diff) |
Change rgblight_get_mode & rgb_matrix_get_mode's return type to uint8_t. (#4747)
* Change rgblight_get_mode's return type to uint8_t.
Since rgblight_get_mode() is just returning rgblight_config_t.mode,
it should match rgblight_config_t.mode's type: uint8_t.
* Update rgb_matrix_get_mode to return uint8_t.
-rw-r--r-- | keyboards/mxss/rgblight.c | 2 | ||||
-rw-r--r-- | quantum/rgb_matrix.c | 2 | ||||
-rw-r--r-- | quantum/rgb_matrix.h | 2 | ||||
-rw-r--r-- | quantum/rgblight.c | 2 | ||||
-rw-r--r-- | quantum/rgblight.h | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/keyboards/mxss/rgblight.c b/keyboards/mxss/rgblight.c index da7959c6a8..73f94f3ab0 100644 --- a/keyboards/mxss/rgblight.c +++ b/keyboards/mxss/rgblight.c @@ -234,7 +234,7 @@ void rgblight_step_reverse(void) { rgblight_mode(mode); } -uint32_t rgblight_get_mode(void) { +uint8_t rgblight_get_mode(void) { if (!rgblight_config.enable) { return false; } diff --git a/quantum/rgb_matrix.c b/quantum/rgb_matrix.c index 82d36177b5..2ed36304dc 100644 --- a/quantum/rgb_matrix.c +++ b/quantum/rgb_matrix.c @@ -973,7 +973,7 @@ void rgb_matrix_mode_noeeprom(uint8_t mode) { rgb_matrix_config.mode = mode; } -uint32_t rgb_matrix_get_mode(void) { +uint8_t rgb_matrix_get_mode(void) { return rgb_matrix_config.mode; } diff --git a/quantum/rgb_matrix.h b/quantum/rgb_matrix.h index 0cfeb4e069..e43532d11e 100644 --- a/quantum/rgb_matrix.h +++ b/quantum/rgb_matrix.h @@ -180,7 +180,7 @@ void rgb_matrix_increase_speed(void); void rgb_matrix_decrease_speed(void); void rgb_matrix_mode(uint8_t mode); void rgb_matrix_mode_noeeprom(uint8_t mode); -uint32_t rgb_matrix_get_mode(void); +uint8_t rgb_matrix_get_mode(void); #ifndef RGBLIGHT_ENABLE #define rgblight_toggle() rgb_matrix_toggle() diff --git a/quantum/rgblight.c b/quantum/rgblight.c index ae5dca1884..23420ddd87 100644 --- a/quantum/rgblight.c +++ b/quantum/rgblight.c @@ -234,7 +234,7 @@ void rgblight_step_reverse(void) { rgblight_step_reverse_helper(true); } -uint32_t rgblight_get_mode(void) { +uint8_t rgblight_get_mode(void) { if (!rgblight_config.enable) { return false; } diff --git a/quantum/rgblight.h b/quantum/rgblight.h index 99ede43c5b..65dda3f521 100644 --- a/quantum/rgblight.h +++ b/quantum/rgblight.h @@ -167,7 +167,7 @@ void rgblight_enable(void); void rgblight_disable(void); void rgblight_step(void); void rgblight_step_reverse(void); -uint32_t rgblight_get_mode(void); +uint8_t rgblight_get_mode(void); void rgblight_mode(uint8_t mode); void rgblight_set(void); void rgblight_update_dword(uint32_t dword); |