[go: nahoru, domu]

[reland] aura: test for change to NativeWindowOcclusionTrackerWin

Adds tests for recent change to ensure dragging window is not
considered in occlusion calculations.
Specifically
https://chromium-review.googlesource.com/c/chromium/src/+/3149714 .

This test generates a mouse down event on the titlebar followed by
a move. This is done to move the window in the same way the user moves
the window. On windows 7 the mouse down was being clicked on the icon,
triggering a context menu to be shown. The fix is to change the location
of the mouse event so that it doesn't hit the window icon.

Change-Id: Ic7eab8cee7d3111dafcb8929411ca4833642aed9
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/3193876
Commit-Queue: Scott Violet <sky@chromium.org>
Reviewed-by: David Bienvenu <davidbienvenu@chromium.org>
Cr-Commit-Position: refs/heads/main@{#927754}
diff --git a/ui/aura/BUILD.gn b/ui/aura/BUILD.gn
index aa8dc06..a50f504 100644
--- a/ui/aura/BUILD.gn
+++ b/ui/aura/BUILD.gn
@@ -394,6 +394,7 @@
       "//base/test:test_support",
       "//mojo/core/embedder",
       "//testing/gtest",
+      "//ui/base:test_support",
       "//ui/base/ime/init",
       "//ui/display:display",
       "//ui/gfx",