Hack 22. Hack the Mouse

mouse.Many people now use a mouse with
five different buttons. Most likely you use only two of those in
Visual Studio (and the rest of them in Halo). Using a freely
available power toy, you can assign each of your mouse buttons to a
Visual Studio command. First, you will need to download and install
the VSMouseBindings power toy from http://www.gotdotnet.com/team/ide. Once you
have installed the power toy, it will add a new folder to your Tools
Figure 3-17. VSMouseBindings Options

can set a command for each of the different buttons on your mouse.
Whenever you click a button on your mouse, the command you assign to
that button will be executed. Figure 3-17 shows some
of my favorite settings, making undo and redo easily accessible on
the Back and Forward buttons, and also putting BuildSolution on the
middle button. You can configure the mouse to execute whatever
commands make sense for you.
|
your command assignments. Using the drop-down labeled
"Use this mouse shortcut in:", you
can set the scope of your command. The available
scope settings are Global, HTML Source Editor, HTML Designer, and
Source Editor. When determining scope, the more specific settings
will override the global settings. You might have the middle button
configured to be BuildSolution at the global level, but set to be
OpenFile in the source editor. This means that the setting for the
source editor will override the global settings; if you click the
middle button on your mouse in source code view, the OpenFile command
will be called.The VSMouseBindings power toy is easy to download, easy to use, and
can definitely make it easier to move around in Visual
Studio.