Skip to content

Fix: Quick Bar not launching on windows#7293

Merged
bramkragten merged 1 commit intohome-assistant:devfrom
donkawechico:quick_bar_windows_fix
Oct 13, 2020
Merged

Fix: Quick Bar not launching on windows#7293
bramkragten merged 1 commit intohome-assistant:devfrom
donkawechico:quick_bar_windows_fix

Conversation

@donkawechico
Copy link
Copy Markdown
Contributor

Proposed change

Fixes bug with Quick Bar on Windows.

Code was only looking for e.metaKey which is true for mac OS's "⌘" but not Windows's Control Key.

Type of change

  • Dependency upgrade
  • Bugfix (non-breaking change which fixes an issue)
  • New feature (thank you!)
  • Breaking change (fix/feature causing existing functionality to break)
  • Code quality improvements to existing code or addition of tests

Example configuration

Additional information

  • This PR fixes or closes issue: fixes #
  • This PR is related to issue:
  • Link to documentation pull request:

Checklist

  • The code change is tested and works locally.
  • There is no commented out code in this PR.
  • Tests have been added to verify that the new code works.

If user exposed functionality or configuration variables are added/changed:

@donkawechico donkawechico force-pushed the quick_bar_windows_fix branch from 2fdccc9 to 2652451 Compare October 9, 2020 23:52
@donkawechico donkawechico changed the title Fix issue with Quick Bar not launching on windows Fix: Quick Bar not launching on windows Oct 9, 2020
@donkawechico donkawechico force-pushed the quick_bar_windows_fix branch from 2652451 to 30300a0 Compare October 9, 2020 23:53
Copy link
Copy Markdown
Contributor

@zsarnett zsarnett left a comment

Choose a reason for hiding this comment

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

Confirmed working on Windows Chrome now

}

private isOSCtrlKey(e: KeyboardEvent) {
return isMacOS ? e.metaKey : e.ctrlKey;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Lets just add this to the if?

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.

I'm personally a fan of using tiny, well-named functions that explain, without code comments, why something's being done.

But I'm fine with whatever here.

@bramkragten bramkragten merged commit 5de225d into home-assistant:dev Oct 13, 2020
@bramkragten bramkragten mentioned this pull request Oct 21, 2020
@github-actions github-actions bot locked and limited conversation to collaborators Jul 5, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants