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

Unified Diff: services/ui/ws/window_tree.cc

Issue 2689283003: chromeos: removes underlay surface offset (Closed)
Patch Set: log error Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « services/ui/ws/window_tree.h ('k') | ui/aura/mus/window_manager_delegate.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: services/ui/ws/window_tree.cc
diff --git a/services/ui/ws/window_tree.cc b/services/ui/ws/window_tree.cc
index ce6c4a6ea32c1c4c890e4aca53bc3315951d4468..fbef1f3b914ad234414a29bd687686557aeae0ac 100644
--- a/services/ui/ws/window_tree.cc
+++ b/services/ui/ws/window_tree.cc
@@ -1938,16 +1938,17 @@ void WindowTree::ActivateNextWindow() {
(*displays.begin())->ActivateNextWindow();
}
-void WindowTree::SetUnderlaySurfaceOffsetAndExtendedHitArea(
- Id window_id,
- int32_t x_offset,
- int32_t y_offset,
- const gfx::Insets& hit_area) {
+void WindowTree::SetExtendedHitArea(Id window_id, const gfx::Insets& hit_area) {
ServerWindow* window = GetWindowByClientId(ClientWindowId(window_id));
- if (!window)
+ // Extended hit test region should only be set by the owner of the window.
+ if (!window) {
+ DVLOG(1) << "SetExtendedHitArea supplied unknown window";
return;
-
- window->SetUnderlayOffset(gfx::Vector2d(x_offset, y_offset));
+ }
+ if (window->id().client_id != id_) {
+ DVLOG(1) << "SetExtendedHitArea supplied window that client does not own";
+ return;
+ }
window->set_extended_hit_test_region(hit_area);
}
« no previous file with comments | « services/ui/ws/window_tree.h ('k') | ui/aura/mus/window_manager_delegate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698