| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/chrome_shell_delegate.h" | 5 #include "chrome/browser/ui/ash/chrome_shell_delegate.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "ash/content/gpu_support_impl.h" | 9 #include "ash/content/gpu_support_impl.h" |
| 10 #include "ash/session/session_state_delegate.h" | 10 #include "ash/session/session_state_delegate.h" |
| (...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 136 } | 136 } |
| 137 | 137 |
| 138 ui::MenuModel* ChromeShellDelegate::CreateContextMenu( | 138 ui::MenuModel* ChromeShellDelegate::CreateContextMenu( |
| 139 ash::Shelf* shelf, | 139 ash::Shelf* shelf, |
| 140 const ash::ShelfItem* item) { | 140 const ash::ShelfItem* item) { |
| 141 DCHECK(shelf_delegate_); | 141 DCHECK(shelf_delegate_); |
| 142 // Don't show context menu for exclusive app runtime mode. | 142 // Don't show context menu for exclusive app runtime mode. |
| 143 if (chrome::IsRunningInAppMode()) | 143 if (chrome::IsRunningInAppMode()) |
| 144 return nullptr; | 144 return nullptr; |
| 145 | 145 |
| 146 return new LauncherContextMenu(shelf_delegate_, item, shelf); | 146 return LauncherContextMenu::CreateLauncherContextMenu(shelf_delegate_, item, |
| 147 shelf); |
| 147 } | 148 } |
| 148 | 149 |
| 149 ash::GPUSupport* ChromeShellDelegate::CreateGPUSupport() { | 150 ash::GPUSupport* ChromeShellDelegate::CreateGPUSupport() { |
| 150 // Chrome uses real GPU support. | 151 // Chrome uses real GPU support. |
| 151 return new ash::GPUSupportImpl; | 152 return new ash::GPUSupportImpl; |
| 152 } | 153 } |
| 153 | 154 |
| 154 base::string16 ChromeShellDelegate::GetProductName() const { | 155 base::string16 ChromeShellDelegate::GetProductName() const { |
| 155 return l10n_util::GetStringUTF16(IDS_PRODUCT_NAME); | 156 return l10n_util::GetStringUTF16(IDS_PRODUCT_NAME); |
| 156 } | 157 } |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 201 | 202 |
| 202 void ChromeShellDelegate::AddVirtualKeyboardStateObserver( | 203 void ChromeShellDelegate::AddVirtualKeyboardStateObserver( |
| 203 ash::VirtualKeyboardStateObserver* observer) { | 204 ash::VirtualKeyboardStateObserver* observer) { |
| 204 keyboard_state_observer_list_.AddObserver(observer); | 205 keyboard_state_observer_list_.AddObserver(observer); |
| 205 } | 206 } |
| 206 | 207 |
| 207 void ChromeShellDelegate::RemoveVirtualKeyboardStateObserver( | 208 void ChromeShellDelegate::RemoveVirtualKeyboardStateObserver( |
| 208 ash::VirtualKeyboardStateObserver* observer) { | 209 ash::VirtualKeyboardStateObserver* observer) { |
| 209 keyboard_state_observer_list_.RemoveObserver(observer); | 210 keyboard_state_observer_list_.RemoveObserver(observer); |
| 210 } | 211 } |
| OLD | NEW |