summaryrefslogtreecommitdiffstats
path: root/widget
diff options
context:
space:
mode:
Diffstat (limited to 'widget')
-rw-r--r--widget/windows/nsNativeThemeWin.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/widget/windows/nsNativeThemeWin.cpp b/widget/windows/nsNativeThemeWin.cpp
index 8950dcf90..475ebce94 100644
--- a/widget/windows/nsNativeThemeWin.cpp
+++ b/widget/windows/nsNativeThemeWin.cpp
@@ -1360,7 +1360,10 @@ nsNativeThemeWin::GetThemePartAndState(nsIFrame* aFrame, uint8_t aWidgetType,
static bool
AssumeThemePartAndStateAreTransparent(int32_t aPart, int32_t aState)
{
- if (aPart == MENU_POPUPITEM && aState == MBI_NORMAL) {
+ // When using a high contrast theme on Windows 8 or later, we can't
+ // use this optimization.
+ if (!(IsWin8OrLater() && nsUXThemeData::IsHighContrastOn()) &&
+ aPart == MENU_POPUPITEM && aState == MBI_NORMAL) {
return true;
}
return false;