Closed koron closed 6 months ago
https://docs.qmk.fm/#/feature_layers
MO(layer)
- momentarily activates layer. As soon as you let go of the key, the layer is deactivated.
AML_*
keys call set_auto_mouse_xxx()
(where xxx
is enable
or timeout
).
set_auto_mouse_xxx()
calls auto_mouse_reset()
.
auto_mouse_reset()
clears the context's status and timer.
the cotext status is cleared, therefore no reasons to keep layer fo auto mouse ON. the layer will be off.
I dought auto_mouse_context.status.mouse_key_tracker
I tried changing auto_mouse_reset()
as follows.
It keeps mouse_key_tracker
beyond auto_mouse_reset()
.
Then this problem is fixed.
It is difficult to fix it with the Keyball alone. It requires modification of the QMK.
static void auto_mouse_reset(void) {
int8_t tmp = auto_mouse_context.status.mouse_key_tracker;
memset(&auto_mouse_context.status, 0, sizeof(auto_mouse_context.status));
memset(&auto_mouse_context.timer, 0, sizeof(auto_mouse_context.timer));
auto_mouse_context.status.mouse_key_tracker = tmp;
}
Give up!
When set
MO()
with the layer which set as auto mouse layer, When holding the key then pressingAML_*
, it turn off (disable) the layer.