-
-
Notifications
You must be signed in to change notification settings - Fork 39.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix bug with layer caching in get_event_keycode #8693
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Are there any docs that need updating, as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
175fb39
to
9102640
Compare
No, it shouldn't. There are a number of per-key features that use this to get the keycode. That's why the "bool" was added and the check for it. It's only "true" and updates the layer cache if it's actually being called from As for needing documentation.... possibly, but not in an existing docs. However, I should probably document why this is the case in the code. |
Could we move the main implementation (i.e. with true) to be a "hidden" api only callable from |
9102640
to
9565a96
Compare
9565a96
to
b1b5176
Compare
in that case, I'll add a note in the code, and change the bool to |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I retested the new changes again and everything is still working.
Tested on xd75:ericgebhart, It is the same code I have for ergodox_ez:ericgebhart. Everything works as expected. Thank you. |
* master: (973 commits) Fix AVR SPI parameter configuration, remove timeouts due to sync protocol. (qmk#8775) VIA Support: Jane V2 (qmk#8735) Add a simple custom keymap for Gergo. (qmk#8662) Add via support to keebio/bdn9 (qmk#8620) DP60 VIA cleanups (qmk#8697) Adding Niu Mini to VIA (qmk#8702) Allow trailing whitespace in markdown docs, for formatting purposes. (qmk#8774) Add support for hardware and board initialisation overrides. (qmk#8330) [Keyboard] Add IDOBAO ID80 (qmk#8728) [Keyboard] Quefrency Rev2 Caps Lock LED, set lighting defaults (qmk#8729) [Keyboard] Add handwired Fc200rt qmk board (qmk#8726) Bugfix for quantum/dip_switch.c (qmk#8731) Add *OPT aliases for *ALT keycodes and macros (qmk#8714) [Keymap] Add keymap for Nyquist rev3 (qmk#8706) format code according to conventions [skip ci] Added Workman ZXCVM variation (qmk#8686) [Keyboard] jotpad16 status leds (qmk#8643) [Keyboard] Add handwired BDN9-BLE (qmk#8192) Fix bug with layer caching in get_event_keycode (qmk#8693) [Keyboard] Add CannonKeys Atlas keyboard (qmk#8207) ...
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
* Fix bug with layer caching in get_event_keycode * Improve naming
Description
Basically, the
get_event_keycode
handler was updating the layer cache when it shouldn't have been. This was causing Layer Tap to get stuck, since it was no longer valid.This adds an additional check to ensure if the layer cache should be updated or not. And updates all of the functions that are calling it (to be "false", so they don't update the layer cache, and instead read the layer cache.
Types of Changes
Issues Fixed or Closed by This PR
Checklist