Open vraravam opened 5 years ago
This has been implemented for a very long time.
Eg,
{
label: `Goto Tab 1`,
accelerator: 'CmdOrCtrl+1',
click() {
sendAction('focusTab', 1);
}
},
If there's a Mac problem here, it's probably in Electron. Try the latest nightly build (with Electron 7.1.4).
If I'm missing something obvious here, I'm happy to fix it.
No response received on this, and the accelerators should be working fine.
This is not working for me - just installed for the first time. Version: 0.6.0 Platform: darwin (x64) Electron: 8.1.1 Chromium: 80.0.3987.141 Node: 12.13.0 BuildVersion: 8871b6c (grafted, HEAD, tag: nightly, origin/master) Sat, 14 Mar 2020 10:07:20 -0700
I have no way to test on MacOS, so likely someone will have to figure out what does and doesn't work, because literally the whole point of CmdOrCtrl
is for it to use Cmd on MacOS and Ctrl on everything else, and that's provided by Electron.
Same here, not working for me. Any troubleshooting we can do to figure it out? Version: 0.6.0 Platform: darwin (x64) Electron: 8.1.1 Chromium: 80.0.3987.141 Node: 12.13.0 BuildVersion: 298af38 (grafted, HEAD, tag: nightly, origin/master) Thu, 2 Apr 2020 15:44:54 -0700
@TheGoddessInari : This is still a dealbreaker for me. Just tried to switch between 2 services. I'm using:
Version: 0.6.0
Platform: darwin (x64)
Electron: 9.1.2
Chromium: 83.0.4103.122
Node: 12.14.1
BuildVersion: 249264e (grafted, HEAD, tag: nightly, origin/master) Fri, 31 Jul 2020 00:37:43 -0700
Also on Mac 0.6.0 -- and not able to switch apps with any keys
FWIW ... doesn't work in v 0.5.20 either
@TheGoddessInari - is there a debug log or something that we can retrieve and attach to this ticket - to help you debug the issue? This definitely doesn't work on MacOS. I tried with a vanilla install on a fresh machine as well. No luck.
Closing this issue since I have moved onto Ferdi.
@TheGoddessInari - I think I have solved the same issue (while contributing to Ferdi). Please see this function: https://github.com/vraravam/ferdi/blob/develop/src/environment.ts#L28
The issue with electron on macos, is that, depending on whether you are using that CmdOrCtrl
for an accelerator or for a menu item, the value needs to be different.
You can follow the logic in the Ferdi codebase (as an example here: https://github.com/vraravam/ferdi/blob/develop/src/components/services/tabs/TabItem.js#L365) - almost all other invocations are done for the shortcut accelerator, whereas in this line, its for the display, and thus the parameter is false
.
I hope this fixes the issue - I will be glad to test this (I'm thinking of moving to Hamsket, and if you can help with the initial setup, I can also start contributing to Hamsket as a contributor)
Now that I am trying to contribute to Hamsket codebase, I was able to setup my laptop to successfully build it.
I am still facing the same issue on macos 12.1 and the latest codebase (HEAD of the master
branch as of right now). Reopening the ticket.
Found the issue: https://github.com/vraravam/hamsket/blob/master/electron/menu.js#L180 - if I remove this line, the shortcuts work on macos
Mainly, I try to navigate using keyboard shortcuts and avoid the use of the trackpad.
Steps to reproduce
Expected behavior
Cmd + should take the user to that configured application. This is the normal way to traverse multiple tabs in any browser on MacOS
Actual behavior
Nothing happens
ENVIRONMENT