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

Unified Diff: components/mus/ws/default_access_policy.cc

Issue 1862853002: Makes WindowTree::SetFocus(null) work (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: moar cleanup Created 4 years, 8 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/ws/default_access_policy.cc
diff --git a/components/mus/ws/default_access_policy.cc b/components/mus/ws/default_access_policy.cc
index 347a058bd85548c3e56b68e8517d47cb4e6b6e09..c45a969859ea35b75463c71f5bca91a927d5764a 100644
--- a/components/mus/ws/default_access_policy.cc
+++ b/components/mus/ws/default_access_policy.cc
@@ -129,7 +129,7 @@ bool DefaultAccessPolicy::CanSetCapture(const ServerWindow* window) const {
}
bool DefaultAccessPolicy::CanSetFocus(const ServerWindow* window) const {
- return WasCreatedByThisConnection(window) ||
+ return !window || WasCreatedByThisConnection(window) ||
delegate_->HasRootForAccessPolicy(window);
}
« no previous file with comments | « components/mus/public/interfaces/window_tree.mojom ('k') | components/mus/ws/window_manager_client_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698