Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cleanup/rgb matrix #5811

Merged
merged 7 commits into from
May 10, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions keyboards/dztech/dz40rgb/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -32,7 +31,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {

};

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz40rgb/keymaps/split_space/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -53,7 +52,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {



extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/ansi/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -38,7 +37,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
};

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
1 change: 0 additions & 1 deletion keyboards/dztech/dz60rgb/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/hhkb/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -39,7 +38,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
};


extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/hhkb_iso/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -39,7 +38,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS),
};

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/iso/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -38,7 +37,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
KC_TRNS, KC_TRNS, KC_TRNS, TO(0), KC_TRNS, KC_TRNS, KC_TRNS, KC_TRNS),
};

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/matthewrobo/keymap.c
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
#include QMK_KEYBOARD_H

extern bool g_suspend_state;

enum dz60rgb_layers {
_QWERTY,
Expand All @@ -26,7 +25,6 @@ enum dz60rgb_keycodes {
#define _V_V_V_ KC_TRNS
#define LT_CAPS LT(_NAV, KC_CAPS)
#define LT_DEL LT(_RGB, KC_DEL)
extern rgb_config_t rgb_matrix_config;
extern bool autoshift_enabled;
#define MT_SLSH RSFT_T(KC_SLSH)
#define MT_APP RALT_T(KC_APP)
Expand Down
2 changes: 0 additions & 2 deletions keyboards/dztech/dz60rgb/keymaps/mekanist/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
#define _LAYER2 2
Expand Down Expand Up @@ -50,7 +49,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {



extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
XScorpion2 marked this conversation as resolved.
Show resolved Hide resolved
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
1 change: 0 additions & 1 deletion keyboards/dztech/dz65rgb/keymaps/default/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;
#define _LAYER0 0
#define _LAYER1 1
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
Expand Down
2 changes: 0 additions & 2 deletions keyboards/massdrop/ctrl/keymaps/matthewrobo/keymap.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
#include QMK_KEYBOARD_H
extern bool g_suspend_state;

enum ctrl_layers {
_QWERTY,
Expand Down Expand Up @@ -31,7 +30,6 @@ enum ctrl_keycodes {
#define TG_NKRO MAGIC_TOGGLE_NKRO //Toggle 6KRO / NKRO mode
#define LT_CAPS LT(_NAV, KC_CAPS)
#define _V_V_V_ KC_TRNS
extern rgb_config_t rgb_matrix_config;
extern bool autoshift_enabled;


Expand Down
4 changes: 0 additions & 4 deletions keyboards/planck/keymaps/tom/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -224,10 +224,6 @@ bool music_mask_user(uint16_t keycode) {
}
}

#ifdef RGB_MATRIX_ENABLE
extern led_config_t g_led_config;
#endif

void rgb_matrix_indicators_user(void) {
#ifdef RGB_MATRIX_ENABLE
switch (biton32(layer_state)) {
Expand Down
1 change: 0 additions & 1 deletion keyboards/sol/keymaps/xulkal/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,6 @@ static void render_logo(void) {
oled_write_P(sol_logo, false);
}

extern rgb_config_t rgb_matrix_config;

static void render_status(void) {
// Render to mode icon
Expand Down
5 changes: 0 additions & 5 deletions layouts/community/ergodox/drashna/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
# define UC(x) KC_NO
#endif

#ifdef RGB_MATRIX_ENABLE
extern bool g_suspend_state;
extern rgb_config_t rgb_matrix_config;
#endif
extern userspace_config_t userspace_config;

enum more_custom_keycodes {
Expand Down Expand Up @@ -403,7 +399,6 @@ void suspend_wakeup_init_keymap(void) {
rgb_matrix_set_suspend_state(false);
}

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue, bool default_layer) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
5 changes: 0 additions & 5 deletions layouts/community/ortho_4x12/drashna/keymap.c
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@
#include QMK_KEYBOARD_H
#include "drashna.h"

#ifdef RGB_MATRIX_ENABLE
extern bool g_suspend_state;
extern rgb_config_t rgb_matrix_config;
#endif
#ifdef RGBLIGHT_ENABLE
extern rgblight_config_t rgblight_config;
#endif
Expand Down Expand Up @@ -184,7 +180,6 @@ void suspend_wakeup_init_keymap(void) {
rgb_matrix_set_suspend_state(false);
}

extern led_config_t g_led_config;
void rgb_matrix_layer_helper (uint8_t red, uint8_t green, uint8_t blue) {
for (int i = 0; i < DRIVER_LED_TOTAL; i++) {
if (HAS_FLAGS(g_led_config.flags[i], LED_FLAG_MODIFIER)) {
Expand Down
Loading