aboutsummaryrefslogtreecommitdiffstats
path: root/tmk_core/common/action.c
AgeCommit message (Collapse)Author
2019-10-17Move tmk_core/common/backlight to quantum/backlight (#6710)Gravatar Joel Challis
* Move tmk_core/common/backlight to quantum/backlight * Add guards to backlight inclusion * Add guards to backlight inclusion * Update backlight guards on clueboard/60 * Use full paths to avoid vpath issues
2019-10-16Fix bug in `do_code16()` (#6935)Gravatar fauxpark
* Fix bug in `do_code16()` * Remove qk_ mods functions
2019-08-30clang-format changesGravatar skullY
2019-08-08Extend allowed range of tappable keycodes to include modifiers (#5809)Gravatar fauxpark
* Extend allowed range of tappable keycodes to include modifiers * Get rid of the magic numbers altogether * Remove some more magic numbers * Extract LM() functionality from ACT_LAYER_TAP * Use ACTION() macro everywhere
2019-07-22Add support for TAP_CODE_DELAY to Hold-Tap keys (#5400)Gravatar Drashna Jaelre
* Add support for TAP_CODE_DELAY to Hold-Tap keys * Better handling for tap code delay and caps version
2019-07-16Make Caps Lock delay more reasonable (#6199)Gravatar Drashna Jaelre
* Make Caps Lock delay more reasonable * Update documentation * Update docs/config_options.md Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com> * Update docs/config_options.md Co-Authored-By: Konstantin Đorđević <vomindoraan@gmail.com>
2019-05-29Fix TO() and DF() calling layer_state_set_[kb,user] twice (#6003)Gravatar fauxpark
2019-05-17Typedef'ed layer_state_t to uint32_t (#3637)Gravatar Alex Ong
* Typedef'ed layer_state_t to uint32_t. This enables future work with layer_state_t to uint8_t for optimization purposes. * Removed accidental xeal60 commit * Revert to egyptian brackets, added sizeof(layer_state_t) so when layer_state_t is redefined it will automagically work. * Add additional typedefs * Add checks for setting layer state * Update tmk_core/common/action_layer.h Co-Authored-By: alex-ong <the.onga@gmail.com> * Revert commit.
2019-05-16Make delay for Capslock in Hold-Tap functions configurable (#5497)Gravatar Drashna Jaelre
* Increase delay for Hold-Tap register for CAPSLOCK Because it seems that the 80ms delay wasn't too much * Screw it, make the caps delay a define and make it configurable
2019-02-10compiles, but long delay on startup and problemsGravatar skullY
2019-01-25Add support for RETRO_TAPPING to LT(layer, kc)Gravatar lambda_sakura
2018-12-28Keep pressed keys on layer state change (fixes #2053, #2279) (#3905)Gravatar Konstantin Đorđević
* Keep pressed keys on layer state change * Add doc comment for clear_keyboard_but_mods_and_keys * Keep pressed keys only if PREVENT_STUCK_MODIFIERS is on * Check STRICT_LAYER_RELEASE instead of PREVENT_STUCK_MODIFIERS
2018-12-14Fix up tap_code functionality (#4609)Gravatar Drashna Jaelre
* Add delay in Tap Code to avoid issues I think a few people have reporting issues with it working properly, and it may be a timing issue. The 'register_code' uses this sort of delay in some of the functions, and this is probably why. Adding the 100ms delay should hopefully fix any issues with it. * Make tap_code delay configurable * Update documentation * Bring tap_code16 inline with changes * Fix type for tap_code16 Bad copy-paste job * Just use the value check for the define * Clarify timing in docs Co-Authored-By: drashna <drashna@live.com> * Wordsmithing Co-Authored-By: drashna <drashna@live.com>
2018-10-04Add mousekey_send to (un)register_codeGravatar Drashna Jaelre
2018-09-17Make `PREVENT_STUCK_MODIFIERS` the default (#3107)Gravatar Joe Wasson
* Remove chording as it is not documented, not used, and needs work. * Make Leader Key an optional feature. * Switch from `PREVENT_STUCK_MODIFIERS` to `STRICT_LAYER_RELEASE` * Remove `#define PREVENT_STUCK_MODIFIERS` from keymaps.
2018-09-03fix mousekey callGravatar Jack Humbert
2018-09-03Enable mouse keys in register_code and unregister_codeGravatar Steven Liu
This allows for macros to be assigned to press two mouse directions at same time, which allows for one key diagonals.
2018-05-14Allow one-shot modifiers to be chainedGravatar Gergely Nagy
Many a times one would want to use multiple modifiers with the same key, preferably without having to hold anything, like `Ctrl+Shift+C` or `Ctrl+Shift+V` to copy/paste in GNOME Terminal. To make this possible, we need to be able to chain one-shot modifiers, so that we can have multiple of them active at the same time. The easiest way to accomplish this is that whenever we activate a one-shot modifier, we apply it on top of the existing set, instead of re-setting the state. When deactivating, either due to an interrupt, or due to a timeout, we deactivate all oneshots anyway, so the clearing part is covered. When we turn the one-shot modifier into a toggle, that will also clear all one-shot modifiers first, so we covered that case too. Fixes #2796, #1580, and #856. Signed-off-by: Gergely Nagy <qmk@gergo.csillger.hu>
2018-03-22Generate API docs from source code comments (#2491)Gravatar skullydazed
* Generate api docs from source code * Add a bunch of doxygen comments * more doxygen comments * Add the in-progress api docs * script to generate docs from travis * Add doc generation to the travis job * make travis_docs.sh commit the work it does * make sure the docs script exits cleanly
2018-03-16Fix swap-hands tapping.Gravatar Joe Wasson
This is an inelegant hack for #2522 but makes things work. Basically we give `action.c` a chance to handle the hold event early so that we can swap the keyboard for later keys. Later, to allow the hold to happen again quickly we nuke the key record so that tapping is reset. I tried to find a cleaner way, honestly.
2018-03-16Rename ONEHAND_ENABLE to SWAP_HANDS_ENABLE for consistencyGravatar Joe Wasson
2018-01-01backlight breathing overhaul (#2187)Gravatar Balz Guenat
* add breathing to bananasplit * backlight breathing overhaul * fix the backlight_tick thing. * fix for vision_division backlight * fix a few keymaps and probably break breathing for some weirdly set-up boards. * remove BL_x keycodes because they made unreasonable assumptions * some fixes for BL keycodes * integer cie lightness scaling * use cie lightness for non-breathing backlight and make breathing able to reach true max brightness
2017-10-31RETRO_TAPPING (#1922)Gravatar tsankuanglee
* add RETRO_TAP: tap anyway, even after TAP_TERM, if no interruption * consistent variable name * add option doc * change name for consistency * make RETRO_TAPPING default to off
2017-10-10#1792 added in waits from tmk for locking switchesGravatar Joe Martin
fixes #1792
2017-06-18Remove noisy debug lineGravatar Carlos Quiroz
2017-06-18Deactivate oneshot mods once timedoutGravatar Carlos Quiroz
2017-05-29Re-enable mouse buttonsGravatar Jack Humbert
2017-05-26- Added integration of IBM TrackpointGravatar dbroqua
2017-05-19Workaround for the macOS caps lock delay (#1308)Gravatar jerryen
* Add 80ms delay for KC_CAPS when used as a tap key Workaround for the macOS caps lock delay * Revert "Increase TAPPING_TERM for the Clueboard" This reverts commit a74e69e9fa889113ee31fbc8dc7e6848fdb07576.
2017-05-10Call led_set for layer action events to update LEDs on layer changesGravatar Nephiel
2017-04-13Fix warnings when ACTION_ONESHOT is disabledGravatar Fred Sundvik
2017-02-13Implement faux-clicky featureGravatar Priyadi Iman Nurcahyo
2017-01-29moved oneshot cancellation code outside of process_record.Gravatar SjB
The oneshot cancellation code do not depend on the action_tapping_process and since process_record get called via the action_tapping_process logic moved the oneshot cancellation code into the action_exec function just before the action_tapping_process call
2017-01-15oneshot timeout would only timeout after an event.Gravatar SjB
After setting a ONESHOT_TIMEOUT value, the oneshot layer state would not expire without an event being triggered (key pressed). The reason was that in the process_record function we would return priort to execute the process_action function if it detected a NOEVENT cycle. The process_action contained the codes to timeout the oneshot layer state. The codes to clear the oneshot layer state have been move just in front of where we check for the NOEVENT cycle in the process_record function.
2016-09-23Fix issue #772 Meh and Hyper not workingGravatar Didier Loiseau
2016-08-20Improve one-hand support by adding more actions and tap keys.Gravatar Joe Wasson
2016-08-20Add one-hand support.Gravatar Joe Wasson
This adds an action, `ACTION_SWAP_HANDS`, that swaps the the keys on the keyboard across a keymap-defined hemisphere in order to support one-hand typing without requiring a separate one-handed layer. See updated `doc/keymap.md` for more information.
2016-05-15splits process_action up to handle records separately (#329)Gravatar Jack Humbert
* implements leader key for planck experimental * allows override of leader timeout * adds ability to use the leader key in seq * fixes leader keycode * adds chording prototype * fixes keycode detection * moves music mode to quantum.c * disables chording by default * adds music sequencer functionality * implements audio/music functions in quantum.c * splits up process_action to allow independent processing of actions * merging?
2016-05-15Leader key implementation (#326)Gravatar Erez Zukerman
* implements leader key for planck experimental * allows override of leader timeout * adds ability to use the leader key in seq * fixes leader keycode * adds chording prototype * fixes keycode detection * moves music mode to quantum.c * disables chording by default * updates process_action functions to return bool
2016-05-05Adds oneshot layer and oneshot tap toggling (#308)Gravatar Thiago Alves
This commit is mostly a cherry-pick from `ahtn` at https://github.com/tmk/tmk_keyboard/pull/255. These are the changes: * Adds ACTION_LAYER_ONESHOT * Adds ONESHOT_TAP_TOGGLE * Mentions sticky keys in the docs on oneshot.
2016-04-28stops forcing debug_actionGravatar Jack Humbert
2016-04-17Fixed many compiler warnings related to print being disabledGravatar IBNobody
2016-04-06Merge pull request #182 from Vifon/modifier-release-fixGravatar Erez Zukerman
Fix the layer-dependent modifiers handling
2016-04-06Fix issue #221: LGUI(KC_LSFT) does not workGravatar Didier Loiseau
on mod keys, register LGUI, LSFT etc. as normal mods instead of weak mods: - they won't be cleared when pressing another key (#188) - they won't be cleared by layer switching - LSFT(KC_LGUI) will now have the same behavior as LGUI(KC_LSFT)
2016-04-05Refactor the source layer cache encodingGravatar Wojciech Siewierski
2016-04-03Merge branch 'master' of https://github.com/jackhumbert/qmk_firmware into ↵Gravatar Wojciech Siewierski
modifier-release-fix
2016-04-02Cleanup after mergeGravatar Wojciech Siewierski
- remove a superfluous parenthesis - wrap lines longer than 80 characters - add const specifiers where appropriate - remove unnecessary casts
2016-04-02Update action.cGravatar eltang
2016-04-02Update action.cGravatar eltang
2016-04-02Update action.cGravatar eltang