Skip to content

Fix arrow keys not working in Hop Web text fields, fixes #7833 - #7853

Open
mattcasters wants to merge 1 commit into
apache:mainfrom
mattcasters:issue-7833
Open

Fix arrow keys not working in Hop Web text fields, fixes #7833#7853
mattcasters wants to merge 1 commit into
apache:mainfrom
mattcasters:issue-7833

Conversation

@mattcasters

Copy link
Copy Markdown
Contributor

What

Fixes arrow (and Home/End/Page Up/Down) keys not moving the caret in Hop Web text fields. Shift+arrow already worked.

Why

Canvas pan shortcuts on bare arrow keys (DragViewZoomBase) were registered as RAP CANCEL_KEYS. That calls preventDefault in the browser for those keys globally, so text fields never get native caret movement.

How

  1. HopWebEntryPoint: keep bare navigation keys in ACTIVE_KEYS (canvas pan still reaches the server when the graph has focus) but exclude them from CANCEL_KEYS, same pattern as Ctrl+C/V/X.
  2. HopGuiKeyHandler: when focus is in Text/Combo/CCombo/StyledText, leave bare navigation keys (and Shift+arrow selection) to the widget so canvas pan does not fire while editing. Ctrl/Cmd/Alt combos still work.

Testing

  • Unit: HopWebEntryPointTest (including new navigation-key case)
  • Manual: verified caret movement and Shift+selection in Hop Web text fields; canvas arrow pan still works when the graph has focus

Fixes #7833

Bare canvas-pan shortcuts were registered as RAP CANCEL_KEYS, so the browser
never moved the caret. Leave navigation keys active but not cancelled, and
stop HopGuiKeyHandler from stealing them inside text-like widgets.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]: Arrow keys don't work in Hop Web text fields

1 participant