Skip to content

fix: Don't loop around when navigating#777

Merged
gonfunko merged 3 commits intoadd-screen-reader-support-experimentalfrom
nav-looping
Dec 10, 2025
Merged

fix: Don't loop around when navigating#777
gonfunko merged 3 commits intoadd-screen-reader-support-experimentalfrom
nav-looping

Conversation

@gonfunko
Copy link
Copy Markdown
Contributor

@gonfunko gonfunko commented Dec 8, 2025

This PR fixes RaspberryPiFoundation/blockly#9496 by disabling looping when using the keyboard to navigate through the workspace, and playing an error tone when the end of the navigable tree is reached.

@microbit-robert
Copy link
Copy Markdown
Contributor

FYI I noticed yesterday that there is still a call to create a LineCursor in index.ts, but it's never used.

@gonfunko
Copy link
Copy Markdown
Contributor Author

gonfunko commented Dec 9, 2025

Oh nice catch, went ahead and cleaned that up.

workspace.getCursor().in();
const newNode = workspace.getCursor().in();
if (!newNode) {
workspace.getAudioManager().beep(260);
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the magic number makes me twitch, but i think the ideal place for this to live is probably an errorBeep function or something in core, so it can stay for now ;p

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, agreed that would be nicer and should be dealt with when we finalize/merge back.

@gonfunko gonfunko merged commit 24edccb into add-screen-reader-support-experimental Dec 10, 2025
4 of 5 checks passed
@gonfunko gonfunko deleted the nav-looping branch December 10, 2025 19:23
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.

3 participants