mirror of
https://github.com/electron/electron.git
synced 2026-04-10 03:01:51 -04:00
fix: nativeTheme.themeSource = 'dark' on windows (#26237)
Manually backports #25373.
This commit is contained in:
@@ -57,6 +57,10 @@ bool IsPictureInPictureEnabled() {
|
||||
return BUILDFLAG(ENABLE_PICTURE_IN_PICTURE);
|
||||
}
|
||||
|
||||
bool IsWinDarkModeWindowUiEnabled() {
|
||||
return BUILDFLAG(ENABLE_WIN_DARK_MODE_WINDOW_UI);
|
||||
}
|
||||
|
||||
bool IsComponentBuild() {
|
||||
#if defined(COMPONENT_BUILD)
|
||||
return true;
|
||||
@@ -84,6 +88,7 @@ void Initialize(v8::Local<v8::Object> exports,
|
||||
dict.SetMethod("isPictureInPictureEnabled", &IsPictureInPictureEnabled);
|
||||
dict.SetMethod("isComponentBuild", &IsComponentBuild);
|
||||
dict.SetMethod("isExtensionsEnabled", &IsExtensionsEnabled);
|
||||
dict.SetMethod("isWinDarkModeWindowUiEnabled", &IsWinDarkModeWindowUiEnabled);
|
||||
}
|
||||
|
||||
} // namespace
|
||||
|
||||
Reference in New Issue
Block a user