summaryrefslogtreecommitdiffstats
path: root/quantum
diff options
context:
space:
mode:
Diffstat (limited to 'quantum')
-rw-r--r--quantum/action.c12
-rw-r--r--quantum/action.h13
2 files changed, 25 insertions, 0 deletions
diff --git a/quantum/action.c b/quantum/action.c
index dadb88e9df..9a6bbcca11 100644
--- a/quantum/action.c
+++ b/quantum/action.c
@@ -165,6 +165,18 @@ void set_swap_hands_state(size_t index, uint8_t *swap_state, bool on) {
}
}
+void swap_hands_on(void) {
+ swap_hands = true;
+}
+
+void swap_hands_off(void) {
+ swap_hands = false;
+}
+
+void swap_hands_toggle(void) {
+ swap_hands = !swap_hands;
+}
+
bool is_swap_hands_on(void) {
return swap_hands;
}
diff --git a/quantum/action.h b/quantum/action.h
index 8ef6db6781..2a2c294c5a 100644
--- a/quantum/action.h
+++ b/quantum/action.h
@@ -85,12 +85,25 @@ typedef uint32_t swap_state_row_t;
# endif
/**
+ * @brief Enable swap hands
+ */
+void swap_hands_on(void);
+/**
+ * @brief Disable swap hands
+ */
+void swap_hands_off(void);
+/**
+ * @brief Toggle swap hands enable state
+ */
+void swap_hands_toggle(void);
+/**
* @brief Get the swap hands enable state
*
* @return true
* @return false
*/
bool is_swap_hands_on(void);
+
void process_hand_swap(keyevent_t *record);
#endif