Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Issue 987733002: MacViews: Fix WidgetTest.WidgetDeleted_InOnMousePressed (Closed)

Created:
5 years, 9 months ago by tapted
Modified:
5 years, 9 months ago
Reviewers:
Andre, sadrul
CC:
chromium-reviews, tfarina, chrome-apps-syd-reviews_chromium.org, mac-views-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

MacViews: Fix WidgetTest.WidgetDeleted_InOnMousePressed WidgetTest.WidgetDeleted_InOnMousePressed was failing because the test widget is initialized with a 0x0+0+0 bounds, which is then resized with SetSize(). Since it's also a popup type, widget.cc does not call either of SetInitialBounds{,ForFramelessWindow}. This resulted in a window that was offscreen, so mouse events were not sent to it. To fix, widgets with no initial bounds are put at the top left of the screen rather than the bottom-left. The test was also flaky because the event generator was not retaining the NSWindow. The tests are specifically to cover the widget being destroyed. Cocoa retains the window during event dispatch, so the event simulator should as well. BUG=378134 Committed: https://crrev.com/4e3993692cad3a7835c9cb47954f60f97fdf4c23 Cr-Commit-Position: refs/heads/master@{#319532}

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+16 lines, -5 lines) Patch
M ui/views/cocoa/bridged_native_widget.mm View 1 chunk +9 lines, -0 lines 0 comments Download
M ui/views/test/event_generator_delegate_mac.mm View 3 chunks +7 lines, -5 lines 0 comments Download

Messages

Total messages: 8 (2 generated)
tapted
Hi Andre and sadrul - please take a look (sadrul for ui/views/test owners) Note this ...
5 years, 9 months ago (2015-03-06 12:03:42 UTC) #2
Andre
LGTM
5 years, 9 months ago (2015-03-06 17:52:02 UTC) #3
sadrul
lgtm
5 years, 9 months ago (2015-03-06 22:05:21 UTC) #4
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/987733002/1
5 years, 9 months ago (2015-03-06 22:51:03 UTC) #6
commit-bot: I haz the power
Committed patchset #1 (id:1)
5 years, 9 months ago (2015-03-07 00:14:22 UTC) #7
commit-bot: I haz the power
5 years, 9 months ago (2015-03-07 00:15:00 UTC) #8
Message was sent while issue was closed.
Patchset 1 (id:??) landed as
https://crrev.com/4e3993692cad3a7835c9cb47954f60f97fdf4c23
Cr-Commit-Position: refs/heads/master@{#319532}

Powered by Google App Engine
This is Rietveld 408576698