[MSPAINT] Save paletteWindow visibility (#5167)

According to my registry analysis, HKCU\Software\Microsoft\Windows\CurrentVersion\Applets\Paint\General-Bar4:Visible is the target value.
- Improve ReadDWORD helper function.
- Add ShowPalette registry setting.
- Simplify RegistrySettings::Load and RegistrySettings::Store.
CORE-18867
This commit is contained in:
Katayama Hirofumi MZ 2023-03-18 17:12:28 +09:00 committed by GitHub
parent 422621622d
commit 5ed7db5acb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 57 additions and 36 deletions

View file

@ -200,7 +200,9 @@ _tWinMain (HINSTANCE hThisInstance, HINSTANCE hPrevInstance, LPTSTR lpszArgument
/* creating the palette child window */
RECT paletteWindowPos = {56, 9, 56 + 255, 9 + 32};
paletteWindow.Create(hwnd, paletteWindowPos, NULL, WS_CHILD | WS_VISIBLE, WS_EX_STATICEDGE);
paletteWindow.Create(hwnd, paletteWindowPos, NULL, WS_CHILD, WS_EX_STATICEDGE);
if (registrySettings.ShowPalette)
paletteWindow.ShowWindow(SW_SHOWNOACTIVATE);
// creating the canvas
RECT canvasWindowPos = {0, 0, 0 + 500, 0 + 500};