OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/ui/ash/launcher/extension_app_window_launcher_controlle
r.h" | 5 #include "chrome/browser/ui/ash/launcher/extension_app_window_launcher_controlle
r.h" |
6 | 6 |
7 #include "ash/public/cpp/shelf_types.h" | 7 #include "ash/public/cpp/shelf_types.h" |
8 #include "ash/public/cpp/window_properties.h" | 8 #include "ash/public/cpp/window_properties.h" |
9 #include "ash/shelf/shelf_model.h" | 9 #include "ash/shelf/shelf_model.h" |
10 #include "ash/wm/window_util.h" | 10 #include "ash/wm/window_util.h" |
11 #include "ash/wm_window.h" | |
12 #include "base/stl_util.h" | 11 #include "base/stl_util.h" |
13 #include "base/strings/stringprintf.h" | 12 #include "base/strings/stringprintf.h" |
14 #include "chrome/browser/profiles/profile.h" | 13 #include "chrome/browser/profiles/profile.h" |
15 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h" | 14 #include "chrome/browser/ui/ash/launcher/chrome_launcher_controller.h" |
16 #include "chrome/browser/ui/ash/launcher/extension_app_window_launcher_item_cont
roller.h" | 15 #include "chrome/browser/ui/ash/launcher/extension_app_window_launcher_item_cont
roller.h" |
17 #include "chrome/browser/ui/ash/multi_user/multi_user_window_manager.h" | 16 #include "chrome/browser/ui/ash/multi_user/multi_user_window_manager.h" |
18 #include "extensions/browser/app_window/app_window.h" | 17 #include "extensions/browser/app_window/app_window.h" |
19 #include "extensions/browser/app_window/native_app_window.h" | 18 #include "extensions/browser/app_window/native_app_window.h" |
20 #include "extensions/common/extension.h" | 19 #include "extensions/common/extension.h" |
21 #include "ui/aura/window.h" | 20 #include "ui/aura/window.h" |
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
203 ExtensionAppWindowLauncherController::ControllerForWindow( | 202 ExtensionAppWindowLauncherController::ControllerForWindow( |
204 aura::Window* window) { | 203 aura::Window* window) { |
205 const auto window_iter = window_to_shelf_id_map_.find(window); | 204 const auto window_iter = window_to_shelf_id_map_.find(window); |
206 if (window_iter == window_to_shelf_id_map_.end()) | 205 if (window_iter == window_to_shelf_id_map_.end()) |
207 return nullptr; | 206 return nullptr; |
208 const auto controller_iter = app_controller_map_.find(window_iter->second); | 207 const auto controller_iter = app_controller_map_.find(window_iter->second); |
209 if (controller_iter == app_controller_map_.end()) | 208 if (controller_iter == app_controller_map_.end()) |
210 return nullptr; | 209 return nullptr; |
211 return controller_iter->second; | 210 return controller_iter->second; |
212 } | 211 } |
OLD | NEW |