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/views/ash/chrome_shell_delegate.h" | 5 #include "chrome/browser/ui/views/ash/chrome_shell_delegate.h" |
6 | 6 |
7 #include "ash/launcher/launcher_types.h" | 7 #include "ash/launcher/launcher_types.h" |
8 #include "ash/system/tray/system_tray_delegate.h" | 8 #include "ash/system/tray/system_tray_delegate.h" |
9 #include "ash/wm/partial_screenshot_view.h" | 9 #include "ash/wm/partial_screenshot_view.h" |
10 #include "ash/wm/window_util.h" | 10 #include "ash/wm/window_util.h" |
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
179 content::OpenURLParams(GURL(chrome::kChromeUIMobileSetupURL), | 179 content::OpenURLParams(GURL(chrome::kChromeUIMobileSetupURL), |
180 content::Referrer(), | 180 content::Referrer(), |
181 NEW_FOREGROUND_TAB, | 181 NEW_FOREGROUND_TAB, |
182 content::PAGE_TRANSITION_LINK, | 182 content::PAGE_TRANSITION_LINK, |
183 false)); | 183 false)); |
184 browser->window()->Activate(); | 184 browser->window()->Activate(); |
185 } | 185 } |
186 #endif | 186 #endif |
187 } | 187 } |
188 | 188 |
| 189 content::BrowserContext* ChromeShellDelegate::GetCurrentBrowserContext() { |
| 190 return ProfileManager::GetDefaultProfile(); |
| 191 } |
| 192 |
189 ash::AppListViewDelegate* | 193 ash::AppListViewDelegate* |
190 ChromeShellDelegate::CreateAppListViewDelegate() { | 194 ChromeShellDelegate::CreateAppListViewDelegate() { |
191 // Shell will own the created delegate. | 195 // Shell will own the created delegate. |
192 return new AppListViewDelegate; | 196 return new AppListViewDelegate; |
193 } | 197 } |
194 | 198 |
195 void ChromeShellDelegate::StartPartialScreenshot( | 199 void ChromeShellDelegate::StartPartialScreenshot( |
196 ash::ScreenshotDelegate* screenshot_delegate) { | 200 ash::ScreenshotDelegate* screenshot_delegate) { |
197 ash::PartialScreenshotView::StartPartialScreenshot(screenshot_delegate); | 201 ash::PartialScreenshotView::StartPartialScreenshot(screenshot_delegate); |
198 } | 202 } |
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
230 ash::Shell::GetInstance()->CreateLauncher(); | 234 ash::Shell::GetInstance()->CreateLauncher(); |
231 break; | 235 break; |
232 default: | 236 default: |
233 NOTREACHED() << "Unexpected notification " << type; | 237 NOTREACHED() << "Unexpected notification " << type; |
234 } | 238 } |
235 #else | 239 #else |
236 // MSVC++ warns about switch statements without any cases. | 240 // MSVC++ warns about switch statements without any cases. |
237 NOTREACHED() << "Unexpected notification " << type; | 241 NOTREACHED() << "Unexpected notification " << type; |
238 #endif | 242 #endif |
239 } | 243 } |
OLD | NEW |