New issue
Advanced search Search tips

Issue 646734 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Oct 2017
Components:
EstimatedDays: ----
NextAction: ----
OS: Mac
Pri: 3
Type: Bug

Blocking:
issue 671916
issue 673589


Show other hotlists

Hotlists containing this issue:
MacViews-Task-Queue


Sign in to add a comment

MacViewsBrowser: No/Incorrect window shadow for Find In Page popup.

Project Member Reported by karandeepb@chromium.org, Sep 14 2016

Issue description

Version: 55.0.2860.0
OS: Mac

What steps will reproduce the problem?
(1) Build MacViews Browser.
(2) Try launching the Find In Page popup multiple times by pressing Cmd+F.
(3) Notice most of the times, the popup does not have a window shadow.
(4) Launch the popup and switch to a new tab.
(5) Switch to the previous tab again. 
(6) Notice the popup does not again have a window shadow.


 
Bug in steps (4)-(6) should be solved by https://codereview.chromium.org/2336983002/. 
Bug in steps (1)-(3) seems to be caused by the Slide Animation with which the Find-In-Page popup is shown.
Project Member

Comment 3 by bugdroid1@chromium.org, Sep 15 2016

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

commit e5cbef5ab4cea989839c24925113f5a062a2fb9a
Author: karandeepb <karandeepb@chromium.org>
Date: Thu Sep 15 08:06:07 2016

MacViews: Trigger shadow invalidation when a translucent window is shown.

Currently, invalidate_shadow_on_frame_swap_ is not set when a MacViews window is
shown. It is only set when the layer is created, changed or the window resized.
This causes translucent windows like the "Restore Pages" bubble and Find-In-Page
window to not have a shadow, when they are shown after being hidden.

This CL modifies BridgedNativeWidget::OnVisibilityChanged() to trigger shadow
invalidation while showing translucent windows. This fixes the shadow for the
"Restore Pages" bubble and also of the Find-In-Page window on tab switching. A
unit test is also added which demonstrates the problem.

Note that this does not fix the shadow for the Find-In-Page window when it is
displayed initially on pressing Cmd+F.

BUG= 636707 ,  646734 

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

[modify] https://crrev.com/e5cbef5ab4cea989839c24925113f5a062a2fb9a/ui/views/cocoa/bridged_native_widget.mm
[modify] https://crrev.com/e5cbef5ab4cea989839c24925113f5a062a2fb9a/ui/views/widget/native_widget_mac_unittest.mm

Status: Available (was: Assigned)
Owner: ----
Blocking: 671916
Labels: phase4
Cc: karandeepb@chromium.org
Labels: MacViews-Dialogs
karandeepb@: Was the fix landed in 2336983002 complete, or is there more to this?
Don't think this was fixed. The fix should have solved the bug in steps (4)-(6). See c#1 and c#2.
Labels: M-64
Owner: lgrey@chromium.org
Status: Assigned (was: Available)
lgrey, can you take a peek at this please? :)
Cc: -karandeepb@chromium.org
Project Member

Comment 11 by bugdroid1@chromium.org, Oct 26 2017

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

commit 50302927e77c1b3033af0e1b584abbcf4488866f
Author: Leonard Grey <lgrey@chromium.org>
Date: Thu Oct 26 16:21:49 2017

[MacViews] Move FindBar to views shadows

Currently, Views shadows are not drawn on Mac. Instead, the macOS Window Server
draws shadows based on the contents of the window.

This can cause issues when the window's contents are animated in through a
views animation. The window has no way of knowing that the contents have
changed, so it doesn't invalidate its shadow, causing glitches like missing
or partial shadows.

This change restores views shadows on Mac and introduces a new (synthetic)
option to the Shadow enum: DIALOG_SHADOW which disables views shadows on
Mac and renders as SMALL_SHADOW otherwise. DIALOG_SHADOW should be used
in cases where a window can move or overlap the browser window in order
to fall back to the window server.

Bug:  646734 
Change-Id: I5d24a27f0d0455c70c235c91b5580364be7e11e5
Reviewed-on: https://chromium-review.googlesource.com/735754
Commit-Queue: Leonard Grey <lgrey@chromium.org>
Reviewed-by: Trent Apted <tapted@chromium.org>
Cr-Commit-Position: refs/heads/master@{#511840}
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/bubble/bubble_border.cc
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/bubble/bubble_border.h
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/bubble/bubble_border_unittest.cc
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/bubble/bubble_dialog_delegate.cc
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/cocoa/bridged_native_widget.mm
[modify] https://crrev.com/50302927e77c1b3033af0e1b584abbcf4488866f/ui/views/window/dialog_delegate.cc

Comment 12 by lgrey@chromium.org, Oct 27 2017

Status: Fixed (was: Assigned)
Blocking: 673589

Sign in to add a comment