2022-01-27 03:35:27 +01:00
|
|
|
#ifndef _H_EP_WEATHER_UTILITY_H_
|
|
|
|
#define _H_EP_WEATHER_UTILITY_H_
|
|
|
|
#include <Windows.h>
|
|
|
|
#include <stdint.h>
|
2022-03-05 23:04:30 +01:00
|
|
|
#include "../ExplorerPatcher/queryversion.h"
|
|
|
|
#include "../ExplorerPatcher/osutility.h"
|
2022-01-31 01:30:34 +01:00
|
|
|
|
|
|
|
extern void(*RefreshImmersiveColorPolicyState)();
|
|
|
|
extern void(*SetPreferredAppMode)(INT64 bAllowDark);
|
|
|
|
extern void(*AllowDarkModeForWindow)(HWND hWnd, INT64 bAllowDark);
|
|
|
|
extern BOOL(*ShouldAppsUseDarkMode)();
|
|
|
|
extern BOOL(*ShouldSystemUseDarkMode)();
|
|
|
|
|
|
|
|
inline BOOL IsColorSchemeChangeMessage(LPARAM lParam)
|
|
|
|
{
|
|
|
|
BOOL is = FALSE;
|
|
|
|
if (lParam && CompareStringOrdinal(lParam, -1, L"ImmersiveColorSet", -1, TRUE) == CSTR_EQUAL)
|
|
|
|
{
|
|
|
|
is = TRUE;
|
|
|
|
}
|
|
|
|
return is;
|
|
|
|
}
|
|
|
|
|
2022-01-28 03:46:04 +01:00
|
|
|
inline BOOL IsHighContrast()
|
|
|
|
{
|
|
|
|
HIGHCONTRASTW highContrast;
|
|
|
|
ZeroMemory(&highContrast, sizeof(HIGHCONTRASTW));
|
|
|
|
highContrast.cbSize = sizeof(highContrast);
|
|
|
|
if (SystemParametersInfoW(SPI_GETHIGHCONTRAST, sizeof(highContrast), &highContrast, FALSE))
|
|
|
|
return highContrast.dwFlags & HCF_HIGHCONTRASTON;
|
|
|
|
return FALSE;
|
|
|
|
}
|
2022-01-27 03:35:27 +01:00
|
|
|
#endif
|