Closed Zerowalker closed 8 months ago
Might be related with Global Media Keys
option that located at Options > Player > Keys
. You might try disable this setting, restart player and computer.
https://github.com/clsid2/mpc-hc/issues/2204
Sounds much like this.
Might be related with
Global Media Keys
option that located atOptions > Player > Keys
. You might try disable this setting, restart player and computer.
That one is already disabled.
Options > Player > Keys Change the keybinding of Quick Open File.
This is NOT a bug in MPC-HC.
You need to report it to Microsoft or to the developers of the app that shows the notification.
As topic says.
I noticed this odd bug, if i got the player in focus and there is some toast notification,
say a calendar event or something, and you click on it (not just close it), mpc-hc opens the "file dialog",
i believe it's the "Quick Open File".
It's not a big deal but thought it might be good to finally post the issue,
It could perhaps be something on my end, but not sure what that could be if that's the case,
but it should be fairly easy to test by doing the steps above.
Does it happen every time? I had trouble reproducing the other bug since I had to wait for YouTube popups.
Windows version?
Windows 10 22H2 19045.3803
I actually can't seem to reproduce it, tried triggering it with the "Clock" timer app. So it's not always as I thought, will have to keep track next time it happens to see if it's a specific notification or something.
Windows 10 22H2 19045.3803
I actually can't seem to reproduce it, tried triggering it with the "Clock" timer app. So it's not always as I thought, will have to keep track next time it happens to see if it's a specific notification or something.
Thanks. In the past it had to do with Youtube/chrome toast. Something about clicking the notification was triggering a hotkey in mpc-hc, but it shouldn't be possible--unless it's just mass sending keystrokes to players registered with SMTC?
It actually seems to be solved. Must have been solved quite recently. Not sure if it's MPC-HC, Windows or something on my end. But I'm quite sure the issue was there some months ago. I have updated MPC-HC whenever there's been a new release, so I'm currently on 2.1.3
If it comes back, let us know which app notification caused it.
Okay found one that seems to trigger it. When i got an google calender notification from chrome and click "snooze" it opens the file explorer.
Oh wow, so I was right all the time and @clsid2 claimed I was imagining things claiming it was all related to media controls, where it was not. Experienced it again right now with Edge twitter notifications, having an MPC instance open, clicking "dismiss" opens "save a copy" in MPC. I am on Windows 11 23h2 22631.3155 Edge 122 and MPC 2.1.6 and I can reproduce it with 100% getting a Edge twitter notification of a twitter DM. Clicking "dismiss" and having MPC in front opens "save a copy" dialog. Minimizing MPC doesnt trigger it. If another window is in front of mpc it also doesnt happen.
Had removed key binding for "quick open" and now ironically it opens "quick open" instead of "save a copy" when clicking dismiss of the Edge or Chrome notification.
Ok this is definitely a bug in MPC. It seems if you clear a keybinding it doesnt clear it properly. 1st bug. And now comes the weird thing in combination:
I rebound quick open file with something else and now instead of quick open, clicking dismiss goes down to the next in the line and opens "open file/url" even it is empty.
If you now also change the 2nd line to something else like this:
clicking dismiss on the toast widow with mpc on focus now opens the 3rd line open dvd/bd gui.
If you now bind a key to dvd/bd, it goes to the next line opening device when pressing dismiss.
I see ZERO evidence of a bug in MPC-HC.
Those functions can be triggered not just by a keybinding but also by sending a window message with their ID. So Edge must be sending messages to wrong window.
@clsid2 please stop debating again where it is crystal clear this is a bug in MPC. The first one is maybe not a direct bug but I told you now the related BUG IN MPC.
And this is a really dangerous bug.
Chrome/Edge sending "something" to MPC, MPC executing the command from top to bottom first one which it finds with no binding in the key binding list.
if quick open file is not bound, it executes that. if it is bound and open file/url is not bound it executes that, if that one is bound and the next one not it executes that one, until it takes the one which is not bound.
They should not send commands to MPC-HC window.
I can't reproduce with the notifications shown by Windows 11.
Here is test site for triggering notifications: https://www.bennish.net/web-notifications.html
That one is not working. You need a notification with buttons. Twitter for example then let someone send you a direct message with tab open of twitter page and without having dms open. the toast will have a message with a reply and dismiss button. clicking dismiss with mpc in focus triggers the issue.
You need a toast like this with a button under it
Ask Elon Musk to fix his crappy X. I am not using that.
Who spit into your cornflakes when you were a child? Use something else Youtube and Edge and it will also have a dismiss button.
This one works:
Use for example or others too
clicking the mothers day specials button triggers the issue
https://github.com/clsid2/mpc-hc/assets/6721083/b2ffe223-df15-4c0b-8672-7afb31800c6e
It would execute line 1, it wont because bound, goes to 2nd line, it is bound, goes to 3rd line, goes to 4th line and exxecutes open device.
That website does not trigger any actions in MPC-HC here. Clicking on notification just opens website as it should. I even tried setting MPC-HC to always on top.
Look what your "non existing bug" in MPC does if you have the key bindings bound like this:
It wants to delete the file if you click the toast button
https://github.com/clsid2/mpc-hc/assets/6721083/f645a828-f247-41ac-883e-ff43f7d043e5
I think it might be sending some weird mouse action. Try this: -removed-
It says it contains a virus
Wacatac is common false positive by Defender. https://www.virustotal.com/gui/file/e411daa8703569f74752e1eddd56a43b739a336151645210013e3e72bfd352e2
No, the version doesnt fix the issue. tested in a virtualbox VM where the issue also happens.
Try this one: mpc-hc64.zip Will show a prompt if a command get triggered.
If that fails I have another idea to try.
Might be fixed: mpc-hc64.zip
Seems like a bug in Windows.
Is it executing unbound actions? Maybe sent globally with null action?
please stop debating again where it is crystal clear this is a bug in MPC.
It may be a bug in mpc-hc or not. It is certainly undesired behavior. But as it was never an issue before Windows 10 toast popups, the question is whether it is rightly called a bug or simply designed without awareness of a future Windows feature, which may interfere with Accelerators.
https://learn.microsoft.com/en-us/windows/win32/api/winuser/ns-winuser-accel
If Windows is sending mpc-hc signals that are being interpreted as accelerators, is that a Windows bug or an mpc-hc bug? And if it is a Windows bug, do we have the ability to identify when it was sent by windows or the user? We must answer these questions to solve the problem and the dilemma!
Are you able to reproduce it? Because I still can't.
I suspect that Windows is somehow matching against a null value in the accel list. That is of course a major bug. Plus the fact that is trying to send a (keypress) action to MPC window when pressing on a toast button is another bug. But anyway, I have taken some measures against Windows stupidness that will hopefully fix the problem.
Might be fixed:
yes that last one seems to fix the issue
Are you able to reproduce it? Because I still can't.
Nope, not so far.
With global media keys enabled, using the Chrome notifications, I can get a windows message WM_HOTKEY
with APPCOMMAND_MEDIA_PLAY
, even though the notification is only supposed to open a browser link.
Further, I was able to APPCOMMAND_MEDIA_PAUSE
by disabling APPCOMMAND_MEDIA_PLAY
. It seems as if it sends a global APPCOMMAND to every window with the first registered APPCOMMAND.
Like I said. This issue has nothing to do with media keys, never had media remote on in MPC as seen on the example videos above, it was obviously a bug in MPC which @clsid2 seems to has fixed. Not just that MPC executed commands by receiving something but also the list which goes through until finding an empty command binding and then executes that. maybe another bug in MPC that the option for global media keys is ignored.
Like I said. This issue has nothing to do with media keys, never had media remote on in MPC as seen on the example videos above, it was obviously a bug in MPC which @clsid2 seems to has fixed. Not just that MPC executed commands by receiving something but also the list which goes through until finding an empty command binding and then executes that. maybe another bug in MPC that the option for global media keys is ignored.
I disagree. There is no reason for windows to send global media keys appcommand to MPC-HC when you click on a chrome notification. I just reproduced this. Once I understand it better, I will submit a bug to Microsoft.
I disagree.
what do you disagree on again? so it s a magic trick that it happens with no option activated in MPC:
@clsid2 ,
I have been able to find a kind of workaround for the issue I found. If you use this (before registering other commands):
RegisterHotKey(m_pMainWnd->m_hWnd, 0xFFFF, 0, 0);
Then the chrome notifications send 0xFFFF
wParam instead. This can be dropped the same as we drop wParam=0.
If you don't register it, the first one you register gets sent by the toast click.
I disagree.
what do you disagree on again? so it s a magic trick that it happens with no option activated in MPC:
The global media keys is one issue I can reproduce, but I cannot reproduce your specific issue. If I could get access to your machine I'd happily debug what windows messages are coming to your app.
The fact that Windows sends garbage media keys when you click on a notification is enough to prove Microsoft has a major bug with how the toast notifications are being processed. So I wouldn't be at all surprised if they did something else stupid, here. Like, they see that you have NO registered app commands, so they instead send you other kinds of ACCEL commands in an attempt to "integrate" with running applications.
Bottom line, there is no reason to send me an app command because someone wants to click on a chrome popup. But they do it anyway.
You are making assumptions without understanding how it works. MPC-HC is REGISTERING hotkeys with Windows. Windows, in turn, NOTIFIES MPC-HC that the key has been pressed. We do not control Windows decisions on this. When you clear a hotkey and the next hotkey runs instead, it may be a similar behavior to the one I just described about app commands (those are different, only work with global media keys, but similar concept).
If I could get access to your machine
what do you mean my machine? I can reproduce it with 100% chance on any Windows 11 PC, even in virtual machine in virtualbox as seen above.
I can never reproduce it. Send me the VM that can repro it.
I cant, it contains my Windows key and private information and the vm storage file is 60gb in size. It is a fresh Windows 11 installation though. I just installed it some days ago.
Send me a debug file I can execute in the vm which tells you the information you want.
In the past I couldn't reproduce this on windows 10 or 11. Fresh doesn't mean you didn't install anything, etc.
Something is different for you but I don't know what, yet.
Clsid2 has a workaround but the actual bug is unclear.
Nope. Nothing installed or changed on the VM
Thats all.
Tell me what I shall do to give you the information, what would Teamviewer be useful for.
do you have telegram or discord chat (no voice call) or something maybe we can do tv but what would you want to do on it then
I asked how you would do that. do you have discord or telegram or not. give me yours so I can give you the teamiewer data.
Maybe a tiny standalone demo app would be more useful for bug reporting to Microsoft. A basic MFC GUI app that registers some hotkeys and key accels. Then also easy to log all incoming commands.
As topic says.
I noticed this odd bug, if i got the player in focus and there is some toast notification, say a calendar event or something, and you click on it (not just close it), mpc-hc opens the "file dialog", i believe it's the "Quick Open File".
It's not a big deal but thought it might be good to finally post the issue, It could perhaps be something on my end, but not sure what that could be if that's the case, but it should be fairly easy to test by doing the steps above.