Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Global keyboard shortcuts #201

Open
defaude opened this issue Sep 1, 2024 · 1 comment
Open

Global keyboard shortcuts #201

defaude opened this issue Sep 1, 2024 · 1 comment

Comments

@defaude
Copy link

defaude commented Sep 1, 2024

Is your feature request related to a problem? Please describe.

It would be nice to have global keyboard shortcuts to control Overlayed features like e.g.

  • toggling pined / unpinned mode to hide / show the channel tab header w/ buttons
  • opening settings window
  • quitting Overlayed
  • etc.

What do you think?

Tauri should provide most of the heavy lifting needed to support global shortcuts already, so the implementation should not be too much effort, I think.

Describe the solution you'd like

Ideally, the settings UI added a new section for the actions that can be bound, where the user can set up their bindings. This could be done via actually having a "listener" mode where the user can just press the desired shortcut. Regarding the syntax for storing the shortcuts to the config: Why not just use Tauri's format?

These shortcuts should be - obviously - global, i.e. I can press the shortcut while I'm in a game, for example.

Describe alternatives you've considered

Alternatively (and simpler to implement), we could allow inputting a string that declares the desired shortcut, e.g. something like CtrlAltShift+o).

Even simpler is to just add an entry in our config.json without any GUI to start with.

@Hacksore
Copy link
Member

Hacksore commented Sep 2, 2024

yeah the one challenge is we really need to get the tauri store plugin added first so we can have access to the config in rust land.

Then for the first phase of this we can allow users to set them in the config, something like how VSCode does it.

{
  "hotkeys": [
    {
        "key": "cmd+shift+1",
        "command": "pin"
    },
  ]
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants