Commit f8c46ebb authored by Thomas Lukaszewicz's avatar Thomas Lukaszewicz Committed by Commit Bot

Repalced GetInstanceForWebUi() with GetNativeTheme() in glass frame

Bug: 1056916
Change-Id: I473116523113dd420196af63386da02a16ef1015
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2123911Reviewed-by: default avatarAllen Bauer <kylixrd@chromium.org>
Commit-Queue: Thomas Lukaszewicz <tluk@chromium.org>
Cr-Commit-Position: refs/heads/master@{#754541}
parent 3f5ad77c
......@@ -179,6 +179,8 @@ int GlassBrowserFrameView::GetThemeBackgroundXInset() const {
bool GlassBrowserFrameView::HasVisibleBackgroundTabShapes(
BrowserFrameActiveState active_state) const {
DCHECK(GetWidget());
// Pre-Win 8, tabs never match the glass frame appearance.
if (base::win::GetVersion() < base::win::Version::WIN8)
return true;
......@@ -189,7 +191,7 @@ bool GlassBrowserFrameView::HasVisibleBackgroundTabShapes(
// colors).
// TODO(pkasting): https://crbug.com/831769 Change the architecture of the
// high contrast support to respect system colors, then remove this.
if (ui::NativeTheme::GetInstanceForNativeUi()->UsesHighContrastColors())
if (GetNativeTheme()->UsesHighContrastColors())
return true;
return BrowserNonClientFrameView::HasVisibleBackgroundTabShapes(active_state);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment