Prevent duplicate menus being created by explorer

On Vista duplicated Git menu entries are added when you right-click a
folder in the Folders pane.

This is because the Shell calls the handler for the Directory\Background
progid first (with a folder pidl), then calls it again for the other
entries with a data object. So the trick is to check if the Git menu has
already been written.

One way you can do this is by using InsertMenuItem on all menu entries
and adding a unique identifier (your module handle, for example) to the
dwItemData member of the item structure. Then in the QueryContextMenu
function you can check if any menu item has this value and act
accordingly.

[JES: moved hInst back into the Explorer-specific part]

Signed-off-by: johnstevenson <john-stevenson@blueyonder.co.uk>
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Fix find_msysgit_in_path() when PATH is in cmd folder rather than bin

msysgit_in_path() expects the PATH to git.exe to be in "../bin/""
whereas Git for Windows uses "../cmd/". This results in the
PathToMsys registry value being set to "../cmd/git.exe" which means
that git_path() will always fail.

This only happens when the dll is outside the git-cheetah folder, as
can be the case when you are debugging.

Signed-off-by: johnstevenson <john-stevenson@blueyonder.co.uk>