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

Unified Diff: components/mus/public/cpp/lib/window.cc

Issue 1991973003: mash: Preliminary support for widget hit test masks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add bug link for SkPath conversion Created 4 years, 7 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
Index: components/mus/public/cpp/lib/window.cc
diff --git a/components/mus/public/cpp/lib/window.cc b/components/mus/public/cpp/lib/window.cc
index c5a3c310253f2b1e06adea6816d04450505a7cde..7802e6837a6fa580ed60e31d80bc22c9c54aab68 100644
--- a/components/mus/public/cpp/lib/window.cc
+++ b/components/mus/public/cpp/lib/window.cc
@@ -217,6 +217,15 @@ void Window::SetClientArea(
LocalSetClientArea(client_area, additional_client_areas);
}
+void Window::SetHitTestMask(const gfx::Rect& mask) {
+ if (!OwnsWindowOrIsRoot(this))
+ return;
+
+ if (connection_)
+ tree_client()->SetHitTestMask(server_id_, mask);
+ hit_test_mask_ = mask;
+}
+
void Window::SetVisible(bool value) {
if (visible_ == value)
return;

Powered by Google App Engine
This is Rietveld 408576698