New issue
Advanced search Search tips

Issue 614146 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
Closed: Jun 2016
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 1
Type: Bug

Blocking:
issue 495654



Sign in to add a comment

Aero glass top extension 2 px too short in material/hybrid modes

Project Member Reported by pkasting@chromium.org, May 23 2016

Issue description

Chrome Version       : 52.0.2739.0
OS Version: 6.1 (Windows 7, Windows Server 2008 R2)

With either Material or Material-Hybrid modes, the glass frame on Win 7 Aero doesn't extend quite far enough downwards to be fully behind the tabstrip/toolbar.

See attached screenshot.  The relative position of the bottom of the glass region against the toolbar is the same in normal vs. maximized windows as well as in material vs. hybrid windows (even though in hybrid mode the tabstrip is taller; in other words, the glass region gets taller by the same amount).

I don't know if this is a regression or has always been broken.

Things look wrong in popup windows too, although the wrongness is different there (we draw a location bar edge pixel underneath the glass frame edge, leading to a strange-looking 2-px-high divider atop the location bar).

Sending to Bret since he's done some work on the relevant code here.
 
win7.png
152 KB View Download

Comment 1 by bsep@chromium.org, May 23 2016

I'm going on vacation imminently so if anyone else wants to jump on this go ahead.

If I had to guess I probably broke it when I added this line: https://code.google.com/p/chromium/codesearch#chromium/src/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc&q=browser_desktop&sq=package:chromium&l=290, though I'm not 100% sure why that line would be needed in MD because, like the comment says, the corners of the toolbar aren't rounded. Maybe the tabstrip bounds are messed up somehow?
Owner: pkasting@chromium.org
I have a WIP for this, taking.
Status: Fixed (was: Assigned)
Project Member

Comment 4 by bugdroid1@chromium.org, Jun 17 2016

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/35ebe25ae437740f33a039fbf84af2855bc2f15b

commit 35ebe25ae437740f33a039fbf84af2855bc2f15b
Author: pkasting <pkasting@chromium.org>
Date: Fri Jun 17 00:39:05 2016

Fix glass extension on MD for Win 7 and below.

This also makes visible (but minor) changes on non-MD (the color of the
innermost pixel of client edge shifts slightly).  This is because we didn't
previously inset the glass enough for the light pixel of edge to be completely
inside the semitransparent client edge region.

This also fixes the glass extension if we were to scale up larger than 200%
somehow.

All of these problems were caused by incorrectly computing the necessary
extension.  The biggest problem was that the code did not account for the
innermost 2 px of glass being a very light and then very dark pixel.  We need to
inset by that amount additionally.

The code also used the wrong mechanism to convert DIPs to pixels, which I think
would have caused bugs on systems with multiple monitors with different DPI.

BUG= 614146 
TEST=Start Chrome on Win 7 and verify there are no bright or dark lines across the window just above the bottom of the tabstrip.

Review-Url: https://codereview.chromium.org/2056583002
Cr-Commit-Position: refs/heads/master@{#400316}

[modify] https://crrev.com/35ebe25ae437740f33a039fbf84af2855bc2f15b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.cc
[modify] https://crrev.com/35ebe25ae437740f33a039fbf84af2855bc2f15b/chrome/browser/ui/views/frame/browser_desktop_window_tree_host_win.h
[modify] https://crrev.com/35ebe25ae437740f33a039fbf84af2855bc2f15b/chrome/browser/ui/views/frame/glass_browser_frame_view.cc

Sign in to add a comment