aboutsummaryrefslogtreecommitdiffstats
path: root/quantum/process_keycode/process_music.h
diff options
context:
space:
mode:
authorGravatar William Chang <william@factual.com>2019-11-20 22:17:07 -0800
committerGravatar William Chang <william@factual.com>2019-11-20 22:17:07 -0800
commite7f4d56592b3975c38af329e77b4efd9108495e8 (patch)
tree0a416bccbf70bfdbdb9ffcdb3bf136b47378c014 /quantum/process_keycode/process_music.h
parent71493b2f9bbd5f3d18373c518fa14ccafcbf48fc (diff)
parent8416a94ad27b3ff058576f09f35f0704a8b39ff3 (diff)
downloadqmk_firmware-e7f4d56592b3975c38af329e77b4efd9108495e8.tar.gz
Merge remote-tracking branch 'upstream/master'
Diffstat (limited to 'quantum/process_keycode/process_music.h')
-rw-r--r--quantum/process_keycode/process_music.h28
1 files changed, 9 insertions, 19 deletions
diff --git a/quantum/process_keycode/process_music.h b/quantum/process_keycode/process_music.h
index f6753d4f2..292bc5374 100644
--- a/quantum/process_keycode/process_music.h
+++ b/quantum/process_keycode/process_music.h
@@ -21,18 +21,11 @@
#if defined(AUDIO_ENABLE) || (defined(MIDI_ENABLE) && defined(MIDI_BASIC))
-enum music_modes {
- MUSIC_MODE_CHROMATIC,
- MUSIC_MODE_GUITAR,
- MUSIC_MODE_VIOLIN,
- MUSIC_MODE_MAJOR,
- NUMBER_OF_MODES
-};
+enum music_modes { MUSIC_MODE_CHROMATIC, MUSIC_MODE_GUITAR, MUSIC_MODE_VIOLIN, MUSIC_MODE_MAJOR, NUMBER_OF_MODES };
-
-#ifdef MUSIC_MAP
- extern const uint8_t music_map[MATRIX_ROWS][MATRIX_COLS];
-#endif
+# ifdef MUSIC_MAP
+extern const uint8_t music_map[MATRIX_ROWS][MATRIX_COLS];
+# endif
bool process_music(uint16_t keycode, keyrecord_t *record);
@@ -58,14 +51,11 @@ bool music_mask(uint16_t keycode);
bool music_mask_kb(uint16_t keycode);
bool music_mask_user(uint16_t keycode);
-#ifndef SCALE
-#define SCALE (int8_t []){ 0 + (12*0), 2 + (12*0), 4 + (12*0), 5 + (12*0), 7 + (12*0), 9 + (12*0), 11 + (12*0), \
- 0 + (12*1), 2 + (12*1), 4 + (12*1), 5 + (12*1), 7 + (12*1), 9 + (12*1), 11 + (12*1), \
- 0 + (12*2), 2 + (12*2), 4 + (12*2), 5 + (12*2), 7 + (12*2), 9 + (12*2), 11 + (12*2), \
- 0 + (12*3), 2 + (12*3), 4 + (12*3), 5 + (12*3), 7 + (12*3), 9 + (12*3), 11 + (12*3), \
- 0 + (12*4), 2 + (12*4), 4 + (12*4), 5 + (12*4), 7 + (12*4), 9 + (12*4), 11 + (12*4), }
-#endif
+# ifndef SCALE
+# define SCALE \
+ (int8_t[]) { 0 + (12 * 0), 2 + (12 * 0), 4 + (12 * 0), 5 + (12 * 0), 7 + (12 * 0), 9 + (12 * 0), 11 + (12 * 0), 0 + (12 * 1), 2 + (12 * 1), 4 + (12 * 1), 5 + (12 * 1), 7 + (12 * 1), 9 + (12 * 1), 11 + (12 * 1), 0 + (12 * 2), 2 + (12 * 2), 4 + (12 * 2), 5 + (12 * 2), 7 + (12 * 2), 9 + (12 * 2), 11 + (12 * 2), 0 + (12 * 3), 2 + (12 * 3), 4 + (12 * 3), 5 + (12 * 3), 7 + (12 * 3), 9 + (12 * 3), 11 + (12 * 3), 0 + (12 * 4), 2 + (12 * 4), 4 + (12 * 4), 5 + (12 * 4), 7 + (12 * 4), 9 + (12 * 4), 11 + (12 * 4), }
+# endif
-#endif // defined(AUDIO_ENABLE) || (defined(MIDI_ENABLE) && defined(MIDI_BASIC))
+#endif // defined(AUDIO_ENABLE) || (defined(MIDI_ENABLE) && defined(MIDI_BASIC))
#endif