Skip to content

Keyboard events stop firing after selecting a sprite in UI until green flag is clicked #10047

@DavidRMcGinn

Description

@DavidRMcGinn

Expected Behavior

"when space key pressed" block responds to keyboard space key presses, even after user has selected a sprite on the scratch editor's sprite list

Actual Behavior

After user has selected a sprite on the scratch editor's sprite list, the "when space key pressed" block stops responding to keyboard space key presses. Expected behavior resumes after clicking green flag.

Steps to Reproduce

Steps to reproduce the behavior:

  1. Go to 'https://scratch.mit.edu/'
  2. Click on Create, Close the tutorial, drag into Sprite1 Code blocks for "when space key pressed, say Hello! for 2 seconds"
  3. Pressing keyboard space key causes sprite to say "Hello!", which is desired behavior
  4. Click on Sprite1 in the sprite selector pane. Unexpected behavior: Now space key does not cause Hello msg.
  5. Expected behavior is restored by clicking on green flag, or by clicking in the code pane or on the stage. Clicking on stop flag does not restore expected behavior.

Screenshots

Image

System Details

The problem occurs in the browser:
Chrome Version 146.0.7680.165 (Official Build) (64-bit) running on Microsoft Windows 11 Version 25H2

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions