| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "ash/launcher/launcher_types.h" | 9 #include "ash/launcher/launcher_types.h" |
| 10 #include "ash/shell_delegate.h" | 10 #include "ash/shell_delegate.h" |
| 11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
| 12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
| 13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
| 14 | 14 |
| 15 class Browser; | 15 class Browser; |
| 16 class StatusAreaHostAura; | 16 class StatusAreaHostAura; |
| 17 class StatusAreaView; | 17 class StatusAreaView; |
| 18 | 18 |
| 19 namespace views { | 19 namespace views { |
| 20 class View; | 20 class View; |
| 21 } | 21 } |
| 22 | 22 |
| 23 class ChromeShellDelegate : public aura_shell::ShellDelegate { | 23 class ChromeShellDelegate : public ash::ShellDelegate { |
| 24 public: | 24 public: |
| 25 ChromeShellDelegate(); | 25 ChromeShellDelegate(); |
| 26 virtual ~ChromeShellDelegate(); | 26 virtual ~ChromeShellDelegate(); |
| 27 | 27 |
| 28 static ChromeShellDelegate* instance() { return instance_; } | 28 static ChromeShellDelegate* instance() { return instance_; } |
| 29 | 29 |
| 30 StatusAreaView* GetStatusArea(); | 30 StatusAreaView* GetStatusArea(); |
| 31 | 31 |
| 32 // Returns whether a launcher item should be created for |browser|. If an item | 32 // Returns whether a launcher item should be created for |browser|. If an item |
| 33 // should be created |type| is set to the launcher type to create. | 33 // should be created |type| is set to the launcher type to create. |
| 34 static bool ShouldCreateLauncherItemForBrowser( | 34 static bool ShouldCreateLauncherItemForBrowser( |
| 35 Browser* browser, | 35 Browser* browser, |
| 36 aura_shell::LauncherItemType* type); | 36 ash::LauncherItemType* type); |
| 37 | 37 |
| 38 // aura_shell::ShellDelegate overrides; | 38 // ash::ShellDelegate overrides; |
| 39 virtual void CreateNewWindow() OVERRIDE; | 39 virtual void CreateNewWindow() OVERRIDE; |
| 40 virtual views::Widget* CreateStatusArea() OVERRIDE; | 40 virtual views::Widget* CreateStatusArea() OVERRIDE; |
| 41 virtual void RequestAppListWidget( | 41 virtual void RequestAppListWidget( |
| 42 const gfx::Rect& bounds, | 42 const gfx::Rect& bounds, |
| 43 const SetWidgetCallback& callback) OVERRIDE; | 43 const SetWidgetCallback& callback) OVERRIDE; |
| 44 virtual void BuildAppListModel(aura_shell::AppListModel* model) OVERRIDE; | 44 virtual void BuildAppListModel(ash::AppListModel* model) OVERRIDE; |
| 45 virtual aura_shell::AppListViewDelegate* CreateAppListViewDelegate() OVERRIDE; | 45 virtual ash::AppListViewDelegate* CreateAppListViewDelegate() OVERRIDE; |
| 46 virtual void LauncherItemClicked( | 46 virtual void LauncherItemClicked( |
| 47 const aura_shell::LauncherItem& item) OVERRIDE; | 47 const ash::LauncherItem& item) OVERRIDE; |
| 48 virtual bool ConfigureLauncherItem(aura_shell::LauncherItem* item) OVERRIDE; | 48 virtual bool ConfigureLauncherItem(ash::LauncherItem* item) OVERRIDE; |
| 49 | 49 |
| 50 private: | 50 private: |
| 51 static ChromeShellDelegate* instance_; | 51 static ChromeShellDelegate* instance_; |
| 52 | 52 |
| 53 scoped_ptr<StatusAreaHostAura> status_area_host_; | 53 scoped_ptr<StatusAreaHostAura> status_area_host_; |
| 54 | 54 |
| 55 DISALLOW_COPY_AND_ASSIGN(ChromeShellDelegate); | 55 DISALLOW_COPY_AND_ASSIGN(ChromeShellDelegate); |
| 56 }; | 56 }; |
| 57 | 57 |
| 58 #endif // CHROME_BROWSER_UI_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ | 58 #endif // CHROME_BROWSER_UI_VIEWS_AURA_CHROME_SHELL_DELEGATE_H_ |
| OLD | NEW |