Skip to content

Commit

Permalink
Change StubWindow to always notify delegate
Browse files Browse the repository at this point in the history
There is code that assumes if the bounds changes the delegte is always
notified (ozone X11 implementations do this). So, make StubWindow does
this too.

BUG=none
TEST=covered by tests

Change-Id: I9374f4b8196675839e32537401025dcbb15bb2a7
Reviewed-on: https://chromium-review.googlesource.com/526282
Reviewed-by: Sadrul Chowdhury <[email protected]>
Commit-Queue: Scott Violet <[email protected]>
Cr-Commit-Position: refs/heads/master@{#477784}
  • Loading branch information
Scott Violet authored and Commit Bot committed Jun 7, 2017
1 parent 4cd9767 commit cd65501
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 0 additions & 2 deletions testing/buildbot/filters/ash_unittests_mus.filter
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,6 @@
-CursorWindowControllerTest.MoveToDifferentDisplay
-CursorWindowControllerTest.VisibilityTest
-DisplayManagerTest.SoftwareMirroringWithCompositingCursor
-DisplayManagerTest.TestDeviceScaleOnlyChange
-DisplayManagerTest.UnifiedDesktopWith2xDSF
-DisplayManagerTest.UpdateMouseCursorAfterRotateZoom
-DragDropControllerTest.CaptureLostCancelsDragDrop
-DragDropControllerTest.DragCancelAcrossDisplays
Expand Down
5 changes: 3 additions & 2 deletions ui/platform_window/stub/stub_window.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,9 @@ void StubWindow::Close() {
void StubWindow::PrepareForShutdown() {}

void StubWindow::SetBounds(const gfx::Rect& bounds) {
if (bounds_ == bounds)
return;
// Even if the pixel bounds didn't change this call to the delegate should
// still happen. The device scale factor may have changed which effectively
// changes the bounds.
bounds_ = bounds;
delegate_->OnBoundsChanged(bounds);
}
Expand Down

0 comments on commit cd65501

Please sign in to comment.