Skip to content
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

Make qmk_settings respect AUTO_SHIFT definitions. #225

Open
wants to merge 1 commit into
base: vial
Choose a base branch
from

Conversation

riannucci
Copy link

Previously when qmk_settings_reset() was called, it would always
reset auto_shift to 0 (i.e. totally disabled). With this change,
all defined AUTO_SHIFT config macros will instead be used as the
default value.

@riannucci
Copy link
Author

Definitely open to suggestions on how to make the bit sets consistent.

@xyzz
Copy link
Contributor

xyzz commented Aug 18, 2022

This looks like it'd cause auto shift to always be enabled when qmk settings are enabled, since Vial sets

AUTO_SHIFT_ENABLE := yes
in order to pull in the autoshift code.

@riannucci
Copy link
Author

Ah... that's a bummer. Looking closer I think I can change it to use AUTO_SHIFT_DISABLED_AT_STARTUP from https://github.com/vial-kb/vial-qmk/blob/vial/quantum/process_keycode/process_auto_shift.c#L24 and then set that by default in common_features.mk to keep the previous behavior?

@riannucci
Copy link
Author

(and then users could un-define it if they want it enabled at startup)

Another thing I could do would be to invert this define? It doesn't seem to be documented anywhere, and clearly has no effect in Vial currently. Looks like this was added in qmk/qmk_firmware#14201... WDYT?

Previously when `qmk_settings_reset()` was called, it would always
reset `auto_shift` to 0 (i.e. totally disabled). With this change,
all defined AUTO_SHIFT config macros will instead be used as the
default value.

To avoid changing the default behavior, this keeps AUTO_SHIFT off by
default unless the user #undef's AUTO_SHIFT_DISABLED_AT_STARTUP.
@riannucci
Copy link
Author

OK, updated this to use AUTO_SHIFT_DISABLED_AT_STARTUP, which shouldn't affect existing vial configs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants