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

Side by Side Diff: chrome/browser/ui/ash/launcher/extension_app_window_launcher_controller.h

Issue 2839933005: mash: Merge ChromeLauncherController and *Impl subclass. (Closed)
Patch Set: Address comments. Created 3 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 unified diff | Download patch
OLDNEW
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 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLLER_ H_ 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLLER_ H_
6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLLER_ H_ 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLLER_ H_
7 7
8 #include <list> 8 #include <list>
9 #include <map> 9 #include <map>
10 #include <string> 10 #include <string>
11 11
12 #include "base/macros.h" 12 #include "base/macros.h"
13 #include "chrome/browser/ui/ash/launcher/app_window_launcher_controller.h" 13 #include "chrome/browser/ui/ash/launcher/app_window_launcher_controller.h"
14 #include "extensions/browser/app_window/app_window_registry.h" 14 #include "extensions/browser/app_window/app_window_registry.h"
15 #include "ui/aura/window_observer.h" 15 #include "ui/aura/window_observer.h"
16 16
17 namespace aura { 17 namespace aura {
18 class Window; 18 class Window;
19 } 19 }
20 20
21 namespace extensions { 21 namespace extensions {
22 class AppWindow; 22 class AppWindow;
23 } 23 }
24 24
25 class ChromeLauncherControllerImpl; 25 class ChromeLauncherController;
26 class Profile; 26 class Profile;
27 class ExtensionAppWindowLauncherItemController; 27 class ExtensionAppWindowLauncherItemController;
28 28
29 // AppWindowLauncherController observes the app window registry and the 29 // AppWindowLauncherController observes the app window registry and the
30 // aura window manager. It handles adding and removing launcher items from 30 // aura window manager. It handles adding and removing launcher items from
31 // ChromeLauncherControllerImpl. 31 // ChromeLauncherController.
32 class ExtensionAppWindowLauncherController 32 class ExtensionAppWindowLauncherController
33 : public AppWindowLauncherController, 33 : public AppWindowLauncherController,
34 public extensions::AppWindowRegistry::Observer, 34 public extensions::AppWindowRegistry::Observer,
35 public aura::WindowObserver { 35 public aura::WindowObserver {
36 public: 36 public:
37 explicit ExtensionAppWindowLauncherController( 37 explicit ExtensionAppWindowLauncherController(
38 ChromeLauncherControllerImpl* owner); 38 ChromeLauncherController* owner);
39 ~ExtensionAppWindowLauncherController() override; 39 ~ExtensionAppWindowLauncherController() override;
40 40
41 // AppWindowLauncherController: 41 // AppWindowLauncherController:
42 void AdditionalUserAddedToSession(Profile* profile) override; 42 void AdditionalUserAddedToSession(Profile* profile) override;
43 AppWindowLauncherItemController* ControllerForWindow( 43 AppWindowLauncherItemController* ControllerForWindow(
44 aura::Window* window) override; 44 aura::Window* window) override;
45 45
46 // Overridden from AppWindowRegistry::Observer: 46 // Overridden from AppWindowRegistry::Observer:
47 void OnAppWindowIconChanged(extensions::AppWindow* app_window) override; 47 void OnAppWindowIconChanged(extensions::AppWindow* app_window) override;
48 void OnAppWindowShown(extensions::AppWindow* app_window, 48 void OnAppWindowShown(extensions::AppWindow* app_window,
(...skipping 26 matching lines...) Expand all
75 // Map of app launcher id to controller. 75 // Map of app launcher id to controller.
76 AppControllerMap app_controller_map_; 76 AppControllerMap app_controller_map_;
77 77
78 // Allows us to get from an aura::Window to the app shelf id. 78 // Allows us to get from an aura::Window to the app shelf id.
79 WindowToAppShelfIdMap window_to_app_shelf_id_map_; 79 WindowToAppShelfIdMap window_to_app_shelf_id_map_;
80 80
81 DISALLOW_COPY_AND_ASSIGN(ExtensionAppWindowLauncherController); 81 DISALLOW_COPY_AND_ASSIGN(ExtensionAppWindowLauncherController);
82 }; 82 };
83 83
84 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLL ER_H_ 84 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_EXTENSION_APP_WINDOW_LAUNCHER_CONTROLL ER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698