Skip to content

Commit

Permalink
fix: issue #1073
Browse files Browse the repository at this point in the history
  • Loading branch information
fxliang committed Jan 25, 2024
1 parent 9061a1a commit a5af53e
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions WeaselIPCServer/WeaselServerImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,11 +60,9 @@ void ServerImpl::_Finailize()

LRESULT ServerImpl::OnColorChange(UINT uMsg, WPARAM wParam, LPARAM lParam, BOOL& bHandled)
{
if (uMsg == WM_SETTINGCHANGE && (std::wstring((wchar_t*)lParam) == L"ImmersiveColorSet") || uMsg == WM_DWMCOLORIZATIONCOLORCHANGED) {
if (IsUserDarkMode() != m_darkMode) {
m_darkMode = IsUserDarkMode();
m_pRequestHandler->UpdateColorTheme(m_darkMode);
}
if (IsUserDarkMode() != m_darkMode) {
m_darkMode = IsUserDarkMode();
m_pRequestHandler->UpdateColorTheme(m_darkMode);
}
return 0;
}
Expand Down

0 comments on commit a5af53e

Please sign in to comment.