OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/browser_shortcut_launcher_item_controll
er.h" | 5 #include "chrome/browser/ui/ash/launcher/browser_shortcut_launcher_item_controll
er.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "ash/aura/wm_window_aura.h" | 9 #include "ash/aura/wm_window_aura.h" |
10 #include "ash/common/shelf/shelf_delegate.h" | 10 #include "ash/common/shelf/shelf_delegate.h" |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
56 if (chrome::SettingsWindowManager::GetInstance()->IsSettingsBrowser(browser)) | 56 if (chrome::SettingsWindowManager::GetInstance()->IsSettingsBrowser(browser)) |
57 return true; | 57 return true; |
58 return false; | 58 return false; |
59 } | 59 } |
60 | 60 |
61 } // namespace | 61 } // namespace |
62 | 62 |
63 BrowserShortcutLauncherItemController::BrowserShortcutLauncherItemController( | 63 BrowserShortcutLauncherItemController::BrowserShortcutLauncherItemController( |
64 ChromeLauncherController* launcher_controller, | 64 ChromeLauncherController* launcher_controller, |
65 ash::ShelfModel* shelf_model) | 65 ash::ShelfModel* shelf_model) |
66 : LauncherItemController(TYPE_SHORTCUT, | 66 : LauncherItemController(extension_misc::kChromeAppId, |
67 extension_misc::kChromeAppId, | |
68 "", | 67 "", |
69 launcher_controller), | 68 launcher_controller), |
70 shelf_model_(shelf_model) {} | 69 shelf_model_(shelf_model) {} |
71 | 70 |
72 BrowserShortcutLauncherItemController:: | 71 BrowserShortcutLauncherItemController:: |
73 ~BrowserShortcutLauncherItemController() { | 72 ~BrowserShortcutLauncherItemController() { |
74 } | 73 } |
75 | 74 |
76 void BrowserShortcutLauncherItemController::UpdateBrowserItemState() { | 75 void BrowserShortcutLauncherItemController::UpdateBrowserItemState() { |
77 // Determine the new browser's active state and change if necessary. | 76 // Determine the new browser's active state and change if necessary. |
(...skipping 272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 !browser->window()->IsMinimized()) { | 349 !browser->window()->IsMinimized()) { |
351 continue; | 350 continue; |
352 } | 351 } |
353 if (!IsBrowserRepresentedInBrowserList(browser) && | 352 if (!IsBrowserRepresentedInBrowserList(browser) && |
354 !browser->is_type_tabbed()) | 353 !browser->is_type_tabbed()) |
355 continue; | 354 continue; |
356 active_browsers.push_back(browser); | 355 active_browsers.push_back(browser); |
357 } | 356 } |
358 return active_browsers; | 357 return active_browsers; |
359 } | 358 } |
OLD | NEW |