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

Unified Diff: services/ui/public/cpp/lib/window.cc

Issue 2118383002: mus: Disregard windows that explicitly set can_accept_events to be false when sending events. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Move can_accept_events_ to ui::Window; check if top window can accept events. Created 4 years, 5 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: services/ui/public/cpp/lib/window.cc
diff --git a/services/ui/public/cpp/lib/window.cc b/services/ui/public/cpp/lib/window.cc
index ae25fcd96b16f8520db135671fedc7962c8ddcb2..4108046ea437e0b3fb7afe1daacfc5eaaed3978e 100644
--- a/services/ui/public/cpp/lib/window.cc
+++ b/services/ui/public/cpp/lib/window.cc
@@ -447,6 +447,13 @@ void Window::SetCanFocus(bool can_focus) {
client_->SetCanFocus(server_id_, can_focus);
}
+void Window::SetCanAcceptEvents(bool can_accept_events) {
+ if (client_ && can_accept_events_ != can_accept_events) {
sadrul 2016/07/12 19:44:19 Prefer early return. if (can_accept_events_ ==
riajiang 2016/07/12 20:51:40 Done.
+ client_->SetCanAcceptEvents(server_id_, can_accept_events);
+ can_accept_events_ = can_accept_events;
+ }
+}
+
void Window::Embed(ui::mojom::WindowTreeClientPtr client, uint32_t flags) {
Embed(std::move(client), base::Bind(&EmptyEmbedCallback), flags);
}
« no previous file with comments | « no previous file | services/ui/public/cpp/lib/window_tree_client.cc » ('j') | services/ui/public/cpp/window_tree_client.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698