Thumbnail handlers reload (#12996)

This commit is contained in:
Davide Giacometti 2021-09-03 22:24:23 +02:00 committed by GitHub
parent b8236d55e2
commit 0b6d654ec8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 11 additions and 0 deletions

View file

@ -103,6 +103,7 @@ asm
asmx
aspnet
aspx
ASSOCCHANGED
ASYNCWINDOWPLACEMENT
ASYNCWINDOWPOS
atl
@ -844,6 +845,7 @@ IDirectory
IDispatch
IDisposable
idl
IDLIST
IDOK
IDOn
IDR
@ -1855,6 +1857,8 @@ sfgao
SFGAOF
SHAREIMAGELISTS
sharpkeys
SHCNE
SHCNF
shcore
shellapi
SHELLDLL

View file

@ -3,6 +3,8 @@
#include "trace.h"
#include <iostream>
#include <atlstr.h>
#include <powerpreview/thumbnail_provider.h>
#include <ShlObj_core.h>
using namespace std;
@ -98,6 +100,11 @@ namespace PowerPreviewSettings
{
Trace::PowerPreviewSettingsUpdateFailed(this->GetToggleSettingName().c_str(), lastState, newState, enabled);
}
if (dynamic_cast<ThumbnailProviderSettings*>(this))
{
SHChangeNotify(SHCNE_ASSOCCHANGED, SHCNF_IDLIST, NULL, NULL);
}
}
// If process is not elevated, return false as it is not possible to update the registry
else