diff options
author | John Ankarström <john@ankarstrom.se> | 2022-04-02 12:39:47 +0200 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2022-04-02 12:44:31 +0200 |
commit | 7e52a92bac667723885f689a1310d93144bd6a11 (patch) | |
tree | 1e284297c026e56e68982ac4fecdb27455c17fba /c | |
parent | e9978f8d1c1acd2e51a64ad5dbe936417fd094d5 (diff) | |
download | EpisodeBrowser-7e52a92bac667723885f689a1310d93144bd6a11.tar.gz |
Properly hide focus rectangles.
For some reason, UISF_HIDEFOCUS must not be set for the main window.
Diffstat (limited to 'c')
-rw-r--r-- | c/main.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -336,7 +336,7 @@ UpdateTheme() HMODULE hModule; hModule = LoadLibrary(TEXT("uxtheme.dll")); bThemes = hModule && GetProcAddress(hModule,"SetWindowTheme"); - FreeLibrary(hModule); + if (hModule) FreeLibrary(hModule); } if (!bThemes) return; @@ -359,5 +359,6 @@ UpdateTheme() ListView_SetExtendedListViewStyleEx(HDlv, LVS_EX_DOUBLEBUFFER, dwStyle); /* Hide focus rectangles. */ - SendMessage(HWnd, WM_UPDATEUISTATE, MAKEWPARAM(wAction, UISF_HIDEFOCUS), 0); + SendMessage(HElv, WM_UPDATEUISTATE, MAKEWPARAM(wAction, UISF_HIDEFOCUS), 0); + SendMessage(HDlv, WM_UPDATEUISTATE, MAKEWPARAM(wAction, UISF_HIDEFOCUS), 0); } |