feat: add transparency checking to nativeTheme
(#43138)
feat: add transparency checking to nativeTheme
This commit is contained in:
parent
6a5ab8aa35
commit
549e1a22e2
4 changed files with 18 additions and 1 deletions
|
@ -68,6 +68,10 @@ bool NativeTheme::InForcedColorsMode() {
|
|||
return ui_theme_->InForcedColorsMode();
|
||||
}
|
||||
|
||||
bool NativeTheme::GetPrefersReducedTransparency() {
|
||||
return ui_theme_->GetPrefersReducedTransparency();
|
||||
}
|
||||
|
||||
#if BUILDFLAG(IS_MAC)
|
||||
const CFStringRef WhiteOnBlack = CFSTR("whiteOnBlack");
|
||||
const CFStringRef UniversalAccessDomain = CFSTR("com.apple.universalaccess");
|
||||
|
@ -108,7 +112,9 @@ gin::ObjectTemplateBuilder NativeTheme::GetObjectTemplateBuilder(
|
|||
&NativeTheme::ShouldUseHighContrastColors)
|
||||
.SetProperty("shouldUseInvertedColorScheme",
|
||||
&NativeTheme::ShouldUseInvertedColorScheme)
|
||||
.SetProperty("inForcedColorsMode", &NativeTheme::InForcedColorsMode);
|
||||
.SetProperty("inForcedColorsMode", &NativeTheme::InForcedColorsMode)
|
||||
.SetProperty("prefersReducedTransparency",
|
||||
&NativeTheme::GetPrefersReducedTransparency);
|
||||
}
|
||||
|
||||
const char* NativeTheme::GetTypeName() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue