Skip to content

Make StatusButton more generic #2130

@harbaum

Description

@harbaum

Setting "showStatusButton" in an extension makes the little status button dot appear right of the extensions name in the toolbar:

image

This is tightly coupled to scratchlink and enabling this activates major parts of the scratchlink.

There are various other ways to interact with hardware than scratchlink. WebUSB and Web Bluetooth are just two of them. I am working on a WebUSB based setup and would like to be able to control this status button and use it for hardware setup related things. The current setup does not allow this and requires me to mess with the scratch dom directly to setup some custom button to display the hardware status and e.g. connect and disconnect it.

Furthermore for security reasons many frameworks like WebUSB require the hardware setup to be triggered by a manual user interaction (usually called a user gesture in this context). So it would be great if any callback provided by this button would still be flagged as "user gesture" so the button can be used to setup e.g. a WebUSB device.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions