New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 800223 link

Starred by 1 user

Issue metadata

Status: WontFix
Owner: ----
Closed: Feb 2018
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

Background blur not working with rounded corners on TrayBubbleView

Project Member Reported by tetsui@chromium.org, Jan 9 2018

Issue description

Chrome Version: 65.0.3317.0 (Developer Build) (64-bit)
OS: Chrome OS

What steps will reproduce the problem?
(1) Checkout https://crrev.com/c/844406
(2) Comment out line #102 of web_notification_tray.cc in PatchSet #1.

The line disables mask layer that is making the rounded corner of TrayBubbleView.

bubble_view->layer()->parent()->SetMaskLayer(nullptr);

https://crrev.com/c/844406/1/ash/system/web_notification/web_notification_tray.cc#102

(3) Open Notification Center from the right bottom of the shelf.

What is the expected result?
Background blur should be enabled even if the mask layer is set.

What happens instead?
Background blur is disabled.

reveman@: Please triage. Thank you.
 
with_solid_corners_expected.png
60.2 KB View Download
with_rounded_corners_actual.png
72.7 KB View Download
Owner: tetsui@chromium.org
Do you have to use mask layers for rounded corners? They are inefficient and I'm not surprised that blur doesn't work with them.

Comment 2 by tetsui@chromium.org, Jan 15 2018

Cc: steve...@chromium.org sky@chromium.org yawano@chromium.org msw@chromium.org omrilio@chromium.org
Owner: ----
+people who might be familiar with the questions

I'm not familiar with how Views internally works so I have no idea how we can fix this.

My questions are:
* What is the alternative approach to round corners other than using mask layers?
* TrayBubbleView is used in many parts of Chrome OS. Are there any cases where the alternative approach does not work and mask layers should be used? If not, why mask layers are used here historically?
* Who is the right person to ask?

Comment 3 by estade@google.com, Jan 15 2018

You can set the layer to non-opaque and then paint whatever shape on it, which would give you a rounded corner effect, but the bg blur works on what you can see *through* the layer, so the corners would still be blurred, presumably. So, tldr I don't think there's another way unless we change the SetBackgroundBlur api.

* Who is the right person to ask?

I've never figured this out, there doesn't seem to be a "views's use of layers" guru.

Comment 4 by tetsui@chromium.org, Jan 17 2018

Cc: danakj@chromium.org wutao@chromium.org
estade@: Thank you for the information. I would try to consider changing ui::Layer::SetBackgroundBlur. The method seems to be used only from app_list now, so we don't have to care much about regression.

Comment 5 by wutao@chromium.org, Feb 1 2018

tetsui@, why do you use the flag app_list::features::IsBackgroundBlurEnabled in your cl? This flag is default off unless it is EVE. Did you go to the chrome://flags to turn on "Enable background blur"?

Comment 6 by wutao@chromium.org, Feb 1 2018

tetsui@, I played with your patch, and the rounded corner blur works.
I will comment on your cl, so that you know what I changed.
rounded_corner_blur.png
22.6 KB View Download

Comment 7 by wutao@chromium.org, Feb 1 2018

Cc: osh...@chromium.org
Status: WontFix (was: Untriaged)
wutao@ kindly found the way to do this, and it turned out it works as intended.

Thank you so much for your help!

2018-02-04.png
163 KB View Download
The working version is patchset #2 of https://crrev.com/c/844406 .

Sign in to add a comment