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

Unified Diff: ash/mus/top_level_window_factory.cc

Issue 2650833002: Set focusibility correctly when initializing a window in mus+ash. (Closed)
Patch Set: cleanup. Created 3 years, 11 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 | « no previous file | services/ui/public/interfaces/window_manager.mojom » ('j') | services/ui/ws/window_tree.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/mus/top_level_window_factory.cc
diff --git a/ash/mus/top_level_window_factory.cc b/ash/mus/top_level_window_factory.cc
index f3260d0d3482cc0cd3c78df6bd64c6f1a7ac2f03..705bfc28c3c5941c79ff342f4d91bf114eadca89 100644
--- a/ash/mus/top_level_window_factory.cc
+++ b/ash/mus/top_level_window_factory.cc
@@ -21,6 +21,7 @@
#include "services/ui/public/interfaces/window_manager_constants.mojom.h"
#include "ui/aura/mus/property_converter.h"
#include "ui/aura/mus/property_utils.h"
+#include "ui/aura/mus/window_tree_client.h"
#include "ui/aura/window.h"
#include "ui/display/display.h"
@@ -186,6 +187,12 @@ aura::Window* CreateAndParentTopLevelWindow(
// No need to persist this value.
properties->erase(ui::mojom::WindowManager::kWindowIgnoredByShelf_Property);
}
+ if (properties->count(ui::mojom::WindowManager::kFocusable_InitProperty)) {
+ window_manager->window_tree_client()->SetCanFocus(
+ window,
+ mojo::ConvertTo<bool>(
+ (*properties)[ui::mojom::WindowManager::kFocusable_InitProperty]));
+ }
return window;
}
« no previous file with comments | « no previous file | services/ui/public/interfaces/window_manager.mojom » ('j') | services/ui/ws/window_tree.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698