summaryrefslogtreecommitdiffstats
path: root/keyboards/christmas_tree
diff options
context:
space:
mode:
authornoroadsleft <18669334+noroadsleft@users.noreply.github.com>2018-06-01 17:56:39 +0200
committerDrashna Jaelre <drashna@live.com>2018-06-01 17:56:39 +0200
commit0aaff74b39554a4278997c13a25d60f9708ecd01 (patch)
treef372413686ccd11aabb5c7c4b93068b02f14833d /keyboards/christmas_tree
parent7624a4e57e88ddd39dc884f98475df16a9fb1a7a (diff)
downloadqmk_firmware-0aaff74b39554a4278997c13a25d60f9708ecd01.tar.gz
qmk_firmware-0aaff74b39554a4278997c13a25d60f9708ecd01.tar.xz
Refactor and Configurator update for Christmas Tree (#3100)
* Refactor * Configurator update
Diffstat (limited to 'keyboards/christmas_tree')
-rw-r--r--keyboards/christmas_tree/christmas_tree.h2
-rw-r--r--keyboards/christmas_tree/info.json21
-rw-r--r--keyboards/christmas_tree/keymaps/default/keymap.c50
3 files changed, 41 insertions, 32 deletions
diff --git a/keyboards/christmas_tree/christmas_tree.h b/keyboards/christmas_tree/christmas_tree.h
index 1d77fa713..11063c915 100644
--- a/keyboards/christmas_tree/christmas_tree.h
+++ b/keyboards/christmas_tree/christmas_tree.h
@@ -3,7 +3,7 @@
#include "quantum.h"
-#define KEYMAP( \
+#define LAYOUT( \
k00, k01, k02, k03, k04, k05 \
) \
{ \
diff --git a/keyboards/christmas_tree/info.json b/keyboards/christmas_tree/info.json
index d33f9cc46..bb223b0e0 100644
--- a/keyboards/christmas_tree/info.json
+++ b/keyboards/christmas_tree/info.json
@@ -1,13 +1,14 @@
{
- "keyboard_name": "Christmas Tree",
- "keyboard_folder": "christmas_tree",
- "url": "https://www.reddit.com/r/MechanicalKeyboards/comments/7cqxpf/gb_christmas_tree_pcb_gb_now_live/",
- "maintainer": "That-Canadian",
- "width": 3,
- "height": 3,
- "layouts": {
- "2017": {
- "key_count": 6
- }
+ "keyboard_name": "Christmas Tree",
+ "keyboard_folder": "christmas_tree",
+ "url": "https://www.reddit.com/r/MechanicalKeyboards/comments/7cqxpf/gb_christmas_tree_pcb_gb_now_live/",
+ "maintainer": "That-Canadian",
+ "width": 3,
+ "height": 3,
+ "layouts": {
+ "2017": {
+ "key_count": 6,
+ "layout": [{"x":1, "y":0}, {"x":0.5, "y":1}, {"x":1.5, "y":1}, {"x":0, "y":2}, {"x":1, "y":2}, {"x":2, "y":2}]
}
+ }
}
diff --git a/keyboards/christmas_tree/keymaps/default/keymap.c b/keyboards/christmas_tree/keymaps/default/keymap.c
index 38da32628..7880fd625 100644
--- a/keyboards/christmas_tree/keymaps/default/keymap.c
+++ b/keyboards/christmas_tree/keymaps/default/keymap.c
@@ -14,7 +14,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
-#include "christmas_tree.h"
+#include QMK_KEYBOARD_H
extern keymap_config_t keymap_config;
@@ -32,27 +32,35 @@ enum custom_keycodes {
const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = {
-/* Base
- * ,------.
- * | 1 |
- * ,------+------.
- * | 2 | 3 |
- * ,------+------+------.
- * | 4 | FUNC | 6 |
- * `--------------------'
- */
-[_BASE] = KEYMAP(KC_1, KC_2, KC_3, KC_4, MO(_FUNC), KC_6),
+ /* Base
+ * ,------.
+ * | 1 |
+ * ,------+------.
+ * | 2 | 3 |
+ * ,------+------+------.
+ * | 4 | FUNC | 6 |
+ * `--------------------'
+ */
+ [_BASE] = LAYOUT(
+ KC_1,
+ KC_2, KC_3,
+ KC_4, MO(_FUNC), KC_6
+ ),
-/* Func
- * ,------.
- * |BCKLIT|
- * ,------+------.
- * | 8 | 9 |
- * ,------+------+------.
- * | 0 | FUNC | RESET|
- * `--------------------'
- */
-[_FUNC] = KEYMAP(BACKLIT, KC_8, KC_9, KC_0, _______, RESET)
+ /* Func
+ * ,------.
+ * |BCKLIT|
+ * ,------+------.
+ * | 8 | 9 |
+ * ,------+------+------.
+ * | 0 | FUNC | RESET|
+ * `--------------------'
+ */
+ [_FUNC] = LAYOUT(
+ BACKLIT,
+ KC_8, KC_9,
+ KC_0, _______, RESET
+ )
};