How can i disable a mouse button in chrome

Jul 11, 2018
4
0
10
0
how can i disable one of my mouse buttons in chrome? i want to disable mouse 3 in chrome so that i can use it as a push to talk shortcut.
 

Ralston18

Titan
Moderator
What make and model mouse do you have?

Most likely you will need to obtain a programmable mouse. Depending on the mouse and software you may or may not be able to program a button as "push to talk".

Consider a "Push to Talk" switch. Simpler and much more straightforward. Maybe a foot activated switch.
 
Jul 11, 2018
4
0
10
0


I am trying to program my mouse 3 button to be push to talk on Discord and i want to disable it on chrome so that it doesn't take me back to the last page
 

Ralston18

Titan
Moderator
Yes - understood.

However, you need to determine on your system if there is the software equivalent (some string of commands) that will have the same end results as pushing a mouse button.

E.g. some screen icon that when clicked allows you to talk in Discord. So you would skip the graphics part (the icon) and just have the necessary audio related commands sent.

To do that you need to know the string, you need to know if the mouse (button 3) is programmable so when button 3 is pressed the string is sent.


Plus some logic within the "program" that looks at the current audio talk state (on or off) and reverses the state with the button click.


Python/ pyaudio might work. "Might" (full disclosure) because I have just started tinkering with Python and do not have enough knowledge or experience per se to be sure.

Link:


https://www.raspberrypi.org/forums/viewtopic.php?t=157013

Seems to be Linux options as well:

https://askubuntu.com/questions/12100/command-to-mute-and-unmute-a-microphone

The following link may be more useful:

https://ubuntuforums.org/showthread.php?t=2342661

The make and model of your mouse is important. The mouse needs software somewhere that detects the button being pressed (button 3 in your case) and then sends the appropriate "push to talk" commands. And monitors the button so that when the button is released the microphone is muted.

And here is a Chrome related link:

https://superuser.com/questions/296740/disable-mouse-hotkeys-in-chrome

Scripts:

https://autohotkey.com/board/topic/93207-help-me-with-a-scriptmute-and-unmute-microphone/
 

gardenman

Admirable
Herald
I was also thinking maybe a AutoHotKey script as Ralston suggested. You can probably make it automatically catch the button press. See the "Xbutton1" on this page under Advanced Buttons: https://autohotkey.com/docs/KeyList.htm
I don't know if that would be the same button or not. You could test that by trying the following script:

Xbutton1::
MsgBox, You pressed the Xbutton1.
return

Run it, press the button, if you see the message then you know you can detect when the button is pressed. Then you would need to figure out how to make the script send the right info to Discord. You would have to add more to this script:

Xbutton1::
; Put some code here that would send the info to Discord
return

I downloaded and looked at Discord and couldn't figure out the hotkey setup. I set the key up, yet it did nothing. But I also didn't create a server or really set it all the way up, I just was looking around in it. The problem might be detecting when the button is down and when the button is back up and sending the information to Discord to do it all. AHK does supports a "Send" command to send keys to a program.
 
Jul 11, 2018
4
0
10
0


Thank you for that the Xmousebutton program worked perfectly
 

ASK THE COMMUNITY