Page 1 of 1

Mouse Button Mapping

PostPosted: 25. Jul 2008, 18:34
by evilbananas
It would be nice if all the mouse buttons available on the host worked in the guest. I'm running a Windows XP host with a Linux guest; it would be convenient if my mouse's side buttons were available for programs such as Firefox on the guest.

PostPosted: 25. Jul 2008, 20:27
by Sasquatch
I agree. With the Guest Additions, it would be possible to have a transparent passthrough of the mouse events to the guest. It only needs to be written and tested properly. Perhaps something for 1.7.0+.

PostPosted: 1. Sep 2008, 22:26
by kilves76
I'll agree too to bump this up, surfing on a virtual machine is terrible without being able to use mouse extra buttons. :cry:

PostPosted: 1. Sep 2008, 22:44
by Sasquatch
kilves76 wrote:I'll agree too to bump this up, surfing on a virtual machine is terrible without being able to use mouse extra buttons. :cry:

I have a small work around for that. I use mouse gestures. Opera has them build in, but for other applications like IE those are not available. For that, I use StrokeIt. Not the same, but it does let you go back and forward using a smooth move.

PostPosted: 2. Sep 2008, 10:06
by kilves76
This is slightly off topic but funny, I bought a mouse with extra buttons exactly for the reason that I totally dislike mouse gestures :lol: I'll let the idea grow on me..

Re: Mouse Button Mapping

PostPosted: 24. May 2009, 03:42
by Bondrake
Just to note: I was searching google for 'mouse buttons virtualbox' after having this same problem, and found this as the top result. As such, I thought I'd be a good net-denizen and let everyone else on the searchernets know the details of the issue and a workaround that doesn't involve resorting to gestures.

VirtualBox mouse emulation emulates a 3-button mouse. Technically it passes 5 buttons to the guest OS, but 4 and 5 are used for scroll. Thus, the buttons you use for forward/back are not passed to the guest OS thanks to a limitation in virtualbox's emulated mouse driver.

Hope: If enough people want more mouse buttons, I'd bet that someone at Sun would be willing to put in the effort required to directly pass through mouse events from higher-order micen through the Virtual Box Guest Additions.

Workaround: If you have a mouse with software in your host OS that allows for per-application profiles, it is possible to setup a profile for virtualbox.exe that will cause your mouse buttons to trigger keyboard events on your Host OS. This means that, say, if you have Firefox running on your guest OS and want to enable forward/back you setup a profile for the mouse buttons you want to use for that in the mouse software of your host OS with the keyboard shortcuts Firefox uses for forward and back (Alt + Right Arrow and Alt + Left Arrow). I suppose if you wanted to be further contrived you could also set it up such that it passes a key combination that isn't bound to anything on your guest OS and then you could use some key-stroke capture software with per-application profiles on the guest OS to have the mouse buttons do different duties for different applications. I'm not aware of any software that does that though (maybe someone with more knowledge on the subject could chime in here?).

My setup is a Windows 7 host with a Logitech G9. The SetPoint mouse software is leagues better than what I remember using years ago and it's exceptionally easy to setup per-application profiles. With the G9 it actually stores the profiles in memory on the mouse and there's no noticeable lag in the profile switch (so the instant I bring up my virtualbox window it has the profile loaded that sets my side keys as Alt+Right and Alt+Left).