Can I prevent the change of overlay icons?

16

4

Background

Several programs modifiy the icons in explorere to indicate a state ("synched" TortoiseCVS sync overlay etc.)

It is a known fact, that Windows (win7, win8, win10?) can only handle a limited amount of such icons (~15) and there are several related questions (f.e.here).

These overlay-icons are registered in the registry in the branch:

HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers

Location of shell overlay icons in registry

Only the first couple of entries (15?) are actually used, the others are ignored. As a result, having multiple programs installing their own overlay icons can corrupt behaviour of already installed programs.

To fix this, one usually has to go into the registry and delete (or rename) unwanted entries until the wanted ones are on top.

Problem

Recently, I've noticed an increasingly 'aggressive' behavior of several programs fighting for these top-positions. This is most often done by having key-names which start with white-space characters to enforce top-sorting. Dropbox, GoogleDrive, SkyDrive and OneDrive are for example all doing this. Some, like GoogleDrive even use three white-spaces nowadays, but other programs are getting equal...

What is worse, some programs even repair this setting automatically during any automated 'update' (or even update-check or program launch?). So any manual adjustments are regularily undone. I have noticed this at least for GoogleDrive, Dropbox and OneDrive

Question

Is there a way to 'protect' the registry from such automated changes?

Edit (Answer)

Alexey Ivanov has given a good suggestion in the comment below, and so far "revoking registry privileges" has suppressed the problem for me.

BmyGuest

Posted 2016-02-19T08:46:26.333

Reputation: 313

2I've made a fairly big change to your post - the issue is, if you ask for the batch file, it's off topic as we're not a script writing service. Plus, batch may or may not be the best way. By keeping this simple, it will (hopefully) allow different types of answers. Feel free to roll my change back if it's too big, but accept it may be seen as off topic at that point. – Dave – 2016-02-19T09:07:47.990

@ Dave: OK, didn't know that batch-files are off-limit on this site as I've seen plenty of them in answers. I just thought a batch-file might be the "only" solution here, but really, I'm after a solution in whatever way and your edit is fine with me. If you think this increases the acceptance of the post, than thanks a lot. – BmyGuest – 2016-02-19T11:14:49.040

Oh, asking for help with your current batch file is OK (and you'd need to share the code). But asking us to write one for you isn't :) – Dave – 2016-02-19T11:32:35.653

1I'd really love an answer to this. Dropbox is really becoming annoying by always replacing TortoiseSVN icons on every update. I made a script that fixes those and restarts Windows Explorer, but found this question while trying to find a way to avoid having to do that... – Nuno – 2017-01-12T20:02:01.527

@NunoPeralta Would you care putting that script online (maybe as an answer to this question or linked) here? – BmyGuest – 2017-01-13T07:46:21.737

2The first thing that comes to my mind is to revoke write privileges from that registry key. Then no program will be able to modify the registry entries. To allow an application to register it's set of overlay icons, you would need to edit the permissions on the key once again to add write privilege. – Alexey Ivanov – 2017-01-13T12:13:01.763

@AlexeyIvanov Nice idea! I wasn't aware one set write permissions on a key-by-key basis. I will need to give it a try... – BmyGuest – 2017-01-13T15:50:28.150

Answers

13

What I did, since Dropbox is really becoming annoying, is I created a ".reg" file that removes all those Dropbox entries:

Windows Registry Editor Version 5.00

[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt01]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt02]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt03]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt04]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt05]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt06]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt07]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt08]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt09]
[-HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers\   DropboxExt10]

Then, I run a ".cmd" file that executes it and restarts Windows Explorer:

regedit -s FixDropboxTortoiseSVNConflict.reg

taskkill /f /im explorer.exe

start explorer.exe

And TortoiseSVN shows icon overlays again.

Not the most beautiful way of doing things, and may require changing the registry keys above when Dropbox changes them in the future again, but removes some manual work of going to the registry and rename/delete them, one by one :)

Nuno

Posted 2016-02-19T08:46:26.333

Reputation: 705

Great, exactly what I was looking for, thanks! Using start explorer.exein the cmd file makes explorer a background process so the shell window does not remain open after it finishes. – Shlublu – 2017-06-07T16:29:01.403

1If you apply the overlays.reg file in your .cmd with regedit -s overlays.reg you can fix everything in one action. Also you can just delete the whole HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\ShellIconOverlayIdentifiers key and add back the ones required otherwise OneDrive and Dropbox keep adding spaces to the keys. – Dave Anderson – 2017-11-28T02:11:38.150