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

Keyboard Manager: failed to map keys #21877

Open
gnatseira opened this issue Nov 8, 2022 · 25 comments
Open

Keyboard Manager: failed to map keys #21877

gnatseira opened this issue Nov 8, 2022 · 25 comments
Labels
Area-App Compat Issues revolving around application compatibility across PowerToys Issue-Bug Something isn't working Needs-Repro We can't figure out how to make this happen. Please help find a simplified repro. Product-Keyboard Shortcut Manager Issues regarding Keyboard Shortcut Manager

Comments

@gnatseira
Copy link

gnatseira commented Nov 8, 2022

Microsoft PowerToys version

0.64.0

Installation method

PowerToys auto-update

Running as admin

Yes

Area(s) with issue?

Keyboard Manager

Steps to reproduce

I use the Keyboard Manager to map Ctrl to Alt so that I can use Alt + c/v to copy/paste.
In summary, I try to use Alt for shortcuts in many applications.
But it sometimes fails to map Crtl to Alt. When I pressed Alt, it had no response.
I don't know how to reproduce this bug. It happened occassionaly in recent versions.
Even I restart powertoys as admin, it still doesn't work. I have to quit the app, then launch it again to make it work.
You can try the same setting in your powertoys. I believe you can find it easily.

✔️ Expected Behavior

For example, when I press Alt and T, it should open a new tab in Chrome.
Also, Alt + C can copy some texts.

❌ Actual Behavior

It doesn't open a new tab, but open the setting of chrome (i.e., the button next to avatar).
Alt + C cannot copy any text.

Other Software

Chrome 107.0.5304.88.

@gnatseira gnatseira added Issue-Bug Something isn't working Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams labels Nov 8, 2022
@Jay-o-Way
Copy link
Collaborator

Hello and thanks for your message. can you share a screenshot of your settings please?

@mrbagpipe
Copy link

I have the same problem since updating to v0.64.0 and today to v0.64.1

I mapped Alt+Space to Win+1 but it doesn't work anymore

image

@gnatseira
Copy link
Author

gnatseira commented Nov 9, 2022

image
It's the setting in my Keyboard Manager. @Jay-o-Way

@Jay-o-Way
Copy link
Collaborator

I mapped Alt+Space to Win+1 but it doesn't work anymore

@mrbagpipe Can't reproduce that problem, it works fine on my computer.

I use the Keyboard Manager to map Ctrl to Alt so that I can use Alt + c/v to copy/paste.

@gnatseira Again: Working well on my end. Is there anything (any app) that could interfere with (hot)keys?

@Jay-o-Way Jay-o-Way added Product-Keyboard Shortcut Manager Issues regarding Keyboard Shortcut Manager Needs-Repro We can't figure out how to make this happen. Please help find a simplified repro. and removed Needs-Triage For issues raised to be triaged and prioritized by internal Microsoft teams labels Nov 16, 2022
@mrbagpipe
Copy link

@Jay-o-Way I did a small recording of the issue. Is there any logs I can share?

It seems to be random. Sometimes it works for a while after rebooting

Carnac_pGyrbb4NQx

@hyue418
Copy link

hyue418 commented Feb 6, 2023

me too

@gnatseira
Copy link
Author

gnatseira commented Mar 15, 2023

@Jay-o-Way Hi, I found the reason for this issue. When I open WeChat of Tencent Inc., the mapping function fails. I guess that the two softwares blocked other mappings to make its own shortcut keys work. I would appreciate it if you would take the time to fix it. Thanks.

@hyue418
Copy link

hyue418 commented Mar 15, 2023

Yeah, me too. Do not open wechat use no problem, once open wechat will be stuck for a while, and then all the key mapping is invalid, hope the author can fix this problem.

@Jay-o-Way Jay-o-Way added the Area-App Compat Issues revolving around application compatibility across PowerToys label Mar 15, 2023
@mrbagpipe
Copy link

I don't use WeChat but I still experience this issue on a daily basis. I just haven't identified which program is colliding with this keyboard mapping. Once this happens, I usually restart PowerToys and things go back to normal for a little while

@hyue418
Copy link

hyue418 commented Mar 16, 2023

I don't use WeChat but I still experience this issue on a daily basis. I just haven't identified which program is colliding with this keyboard mapping. Once this happens, I usually restart PowerToys and things go back to normal for a little while

There seems to be a lot of conflicting programs. Once I use wechat, it will be invalid. And even restarting the software won't work unless you restart the entire system.

@t3239658
Copy link

Yeah, me too. Do not open wechat use no problem, once open wechat will be stuck for a while, and then all the key mapping is invalid, hope the author can fix this problem.

The same problem, hoping to repair as soon as possible

@monkeycraps
Copy link

is there any log for keyboard mapping changed, or any notify can be hooked to check ?

@gnatseira
Copy link
Author

is there any log for keyboard mapping changed, or any notify can be hooked to check ?

I don't know how to catch logs for keyboard mapping on Windows. But you can try, it can reproduce the result every time by opening WeChat.

@xingyuezhiji
Copy link

电脑睡眠之后重新登录电脑,映射就又生效了,但只要一打开微信小程序,就又会失效

@ifu25
Copy link

ifu25 commented Aug 2, 2023

Win+L 锁定后解锁,或者 Ctrl+Alt+Del 然后再取消就好了😂,可恶的微信~

@w-zhiwei
Copy link

just encountered this problem. Anyone knows the cause?

@ifu25
Copy link

ifu25 commented Sep 21, 2023

电脑睡眠之后重新登录电脑,映射就又生效了,但只要一打开微信小程序,就又会失效

对的对的,打开小程序也不行,我是测试发现微信中点击一个网页链接,通【微信内置的浏览器窗口】打开后就会造成 PowerToys 的快捷键映射失效!微信设置中改为用操作系统自带的浏览器打开就没有问题。

@tedli
Copy link

tedli commented Nov 14, 2023

It seems that, wechat also did something like

hook = SetWindowsHookEx(WH_KEYBOARD_LL, KeyHookProc, GetModuleHandle(NULL), NULL);
, but didn't call hook set by other tools.
return CallNextHookEx(hook, nCode, wParam, lParam);

If so, it's wechat's fault, it's dosen't make sense to try to fix this at powertoys' side.

@ffwindy
Copy link

ffwindy commented Jan 4, 2024

当打开微信的时候,F22按键被按下并没有释放,因此键盘管理器失效,通过软件释放F22之后键盘管理器映射就可以重新使用。请问有快捷释放按键的方法么?

@ffwindy
Copy link

ffwindy commented Jan 4, 2024

当打开微信的时候,F22按键被按下并没有释放,因此键盘管理器失效,通过软件释放F22之后键盘管理器映射就可以重新使用。请问有快捷释放按键的方法么?

image
可以将F22 映射到 disable ,能解决打开微信键盘失灵的问题

@acniray
Copy link

acniray commented Jan 23, 2024

当打开微信的时候,F22按键被按下并没有释放,因此键盘管理器失效,通过软件释放F22之后键盘管理器映射就可以重新使用。请问有快捷释放按键的方法么?

image 可以将F22 映射到 disable ,能解决打开微信键盘失灵的问题

正解在这里。。吐血。。。

@ifu25
Copy link

ifu25 commented Jan 24, 2024

当打开微信的时候,F22按键被按下并没有释放,因此键盘管理器失效,通过软件释放F22之后键盘管理器映射就可以重新使用。请问有快捷释放按键的方法么?

image 可以将F22 映射到 disable ,能解决打开微信键盘失灵的问题

厉害厉害,测试ok,终于完美解决了~⛳

@agenshuuu
Copy link

弟兄们,建议直接转战AutoHotkey:作为一款强大的自动化工具,AutoHotkey可以创建脚本以实现复杂的键盘映射和宏定义,并且它通常不会受到相同级别的冲突影响,因为它是通过独立运行的脚本来管理键盘输入的。
经测试快捷键不会因wechat的启动而受影响,经过一个晚上已经将九个快捷操作全部迁移了,在gpt的帮助下省了很多事。
希望能给你们带来帮助

@Giresharu
Copy link

弟兄们,建议直接转战AutoHotkey:作为一款强大的自动化工具,AutoHotkey可以创建脚本以实现复杂的键盘映射和宏定义,并且它通常不会受到相同级别的冲突影响,因为它是通过独立运行的脚本来管理键盘输入的。 经测试快捷键不会因wechat的启动而受影响,经过一个晚上已经将九个快捷操作全部迁移了,在gpt的帮助下省了很多事。 希望能给你们带来帮助

ahk 似乎优先度没有原本的 win 快捷键高,比如说按下 win+s 的时候必然会先触发搜索,然后再触发 ahk 中的宏。而keyboard manager可以让原本的功能失效。另外我不是很想去改注册表修改这些快捷键,一旦经过什么修复就总是被还原然后又要去搜半天怎么改,太痛苦了

@lns567
Copy link

lns567 commented Apr 7, 2024

当打开微信的时候,F22按键被按下并没有释放,因此键盘管理器失效,通过软件释放F22之后键盘管理器映射就可以重新使用。请问有快捷释放按键的方法么?

image 可以将F22 映射到 disable ,能解决打开微信键盘失灵的问题

好像找不到F22键

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-App Compat Issues revolving around application compatibility across PowerToys Issue-Bug Something isn't working Needs-Repro We can't figure out how to make this happen. Please help find a simplified repro. Product-Keyboard Shortcut Manager Issues regarding Keyboard Shortcut Manager
Projects
Status: No status
Development

No branches or pull requests