Skip to content

Return to the base layout when closing a numpad/D-pad overlay - #2693

Open
MiMoHo wants to merge 1 commit into
HeliBorg:mainfrom
MiMoHo:numpad-dpad-return-to-base
Open

Return to the base layout when closing a numpad/D-pad overlay#2693
MiMoHo wants to merge 1 commit into
HeliBorg:mainfrom
MiMoHo:numpad-dpad-return-to-base

Conversation

@MiMoHo

@MiMoHo MiMoHo commented Jul 23, 2026

Copy link
Copy Markdown

Numpad and D-pad are sibling overlays. Switching directly between them pushed the current one onto the previous-layout stack, so closing the newly shown overlay returned to the other overlay instead of the layout they were opened over. Now a deliberate numpad↔dpad switch replaces without stacking, so closing returns to the base (usually the alphabet). Sliding/chording paths unchanged.

Numpad and D-pad are sibling overlays; switching directly between them pushed the current one onto the previous-layout stack, so closing the newly shown overlay returned to the OTHER overlay instead of the layout they were opened over (usually the alphabet). Switch directly without stacking for a deliberate (non-sliding) numpad<->dpad change.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@devycarol

Copy link
Copy Markdown
Contributor

Interesting take. I can see why it might be unexpected when switching with the toolbar keys, but I don't see any other semantic reason to view them as sisters. I haven't tested this patch, but I wonder how it would affect what happens when you slide from numpad into symbols and release on D-pad or vice versa.

The code seems fine, I just wonder if it should be more specifically generalized around whether the layout was toggled with a toolbar key. More toolbar keys for layout switching could be added in the future. To do this you'd probably have to add some state flag "previousLayoutSwitchWasToolbarKey", which seems cumbersome and easy to lose track of when logic is changed or added.

Remember that regardless of the layout stack status, it will always be cleared and return to alpha when the ABC key is pressed, which is available in the default numpad and D-pad layouts.

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