ysc3839 / win32-darkmode

Example application shows how to use undocumented dark mode API introduced in Windows 10 1809.
MIT License
437 stars 48 forks source link

Dark mode is not supported #20

Closed 0xF5T9 closed 2 years ago

0xF5T9 commented 2 years ago

Hi, I'm sorry if this is a dump question. why it said "Dark mode is not supported" when I call InitDarkMode(), it happen even on the original code. Is it has anything to do with my SDK version, am I missing something? Thank you EDIT: I compiling the project with latest SDK & VS 2022

ysc3839 commented 2 years ago

It checks Windows build number to prevent issues when running on a newer system. https://github.com/ysc3839/win32-darkmode/blob/cc26549b65b25d6f3168a80238792545bd401271/win32-darkmode/DarkMode.h#L179-L185 You should temporary remove that check and test if it working fine on new system, and then add build number to that list. Or you can completely remove the check, but it may cause issues if Microsoft changes these APIs on newer system.

0xF5T9 commented 2 years ago

Thank you so much!