summaryrefslogtreecommitdiffstats
path: root/users/ericgebhart/keymap/map_funcs.h
blob: 0bf20610f3d968e53dc07e0fbd38a9cc7dee6af4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
/*
  Copyright 2022 Eric Gebhart <e.a.gebhart@gmail.com>

  This program is free software: you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation, either version 2 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/
// navigation.  Mouse keys, arrows, home,end, etc.
#ifdef NAV_LAYER_ENABLE
#  ifdef MOUSEKEY_ENABLE
#      undef THUMBS_ARE
#      define THUMBS_ARE MOUSE_LAYER_THUMBS

#    ifdef NAV_FULL_LOCK_MODS
T_LAYER(_NAV, ___NAVA_3x10___),
#    endif

#    ifdef NAV_FULL
  T_LAYER(_NAV, ___NAV_3x10___),
#    endif

#    ifdef NAV_NO_MOUSE
  T_LAYER(_NAV, ___NAVnm_3x10___),
  T_LAYER(_NAVm, ___NAVm_3x10___),
#    endif

// give a default
#    if !defined(NAV_FULL) &&           \
        !defined(NAV_NO_MOUSE) &&       \
        !defined(NAV_FULL_LOCK_MODS)    \

  T_LAYER(_NAV, ___NAVA_3x10___),
#    endif

#    ifdef MOUSE_LAYER_ENABLE
  T_LAYER(_NAVm, ___NAVm_3x10___),
#    endif

#    undef THUMBS_ARE
#    define THUMBS_ARE DEFAULT_THUMBS

#  else // no mouse enable.
  T_LAYER(_NAV, ___NAVnm_3x10___),
#  endif // mousekey end.
#endif //nav end.

#ifdef MEDIA_LAYER_ENABLE
#undef THUMBS_ARE
#define THUMBS_ARE MEDIA_LAYER_THUMBS
  T_LAYER(_MEDIA, ___MEDIA_3x10___),
#undef THUMBS_ARE
#define THUMBS_ARE DEFAULT_THUMBS
#endif

#ifdef FUN_LAYER_ENABLE

#ifdef FUNCPAD_MIRYOKU_ENABLE
  T_LAYER(_FUN, ___FUN_3x10___),
#else
  T_LAYER(_FUN, ___FUN_MIRYOKU_3x10___),
#endif

#endif

// A layer for layers. to set the default, etc.
  T_LAYER(_LAYERS, ___LAYERS_3x10___),

// control the RGB if there are any.
#ifdef RGB_LAYER_ENABLE
  T_LAYER(_RGB, ___RGB_3x10___),
#endif

// control and adjust stuff.
#ifdef ADJUST_LAYER_ENABLE
  T_LAYER(_ADJUST, ___ADJUST_3x10___),
#endif


// put the combo reference layers at the end.
#ifdef COMBO_REF_LAYER_ENABLE
#undef LANG_IS
#define LANG_IS COMBO
#undef EDGE_KEY_SET_IS
#define EDGE_KEY_SET_IS REF1
#undef THUMBS_ARE
#define THUMBS_ARE COMBO
#undef MODS_ARE
#define MODS_ARE TRNS
  B_LAYER(_COMBO_REF, ___10_NUMBERS___, ___COMBO_REF___),
#undef LANG_IS
#define LANG_IS DEFAULT_LANG
#undef EDGE_KEY_SET_IS
#define EDGE_KEY_SET_IS DEFAULT_EDGE_SET
#undef THUMBS_ARE
#define THUMBS_ARE DEFAULT_THUMBS
#undef MODS_ARE
#define MODS_ARE DEFAULT_MODS
#endif

#ifdef COMBO_REF_LAYER_TWO_ENABLE
#undef LANG_IS
#define LANG_IS COMBO2
#undef EDGE_KEY_SET_IS
#define EDGE_KEY_SET_IS REF2
#undef THUMBS_ARE
#define THUMBS_ARE COMBO2
#undef MODS_ARE
#define MODS_ARE TRNS
  B_LAYER(_COMBO_REF2, ___10_NUMBERS___, ___COMBO_REF___),
#undef LANG_IS
#define LANG_IS DEFAULT_LANG
#undef EDGE_KEY_SET_IS
#define EDGE_KEY_SET_IS DEFAULT_EDGE_SET
#undef THUMBS_ARE
#define THUMBS_ARE DEFAULT_THUMBS
#undef MODS_ARE
#define MODS_ARE DEFAULT_MODS
#endif