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 48 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
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(TYPE_SHORTCUT, |
67 extension_misc::kChromeAppId, | 67 extension_misc::kChromeAppId, |
68 "", | 68 "", |
| 69 "", |
69 launcher_controller), | 70 launcher_controller), |
70 shelf_model_(shelf_model) {} | 71 shelf_model_(shelf_model) {} |
71 | 72 |
72 BrowserShortcutLauncherItemController:: | 73 BrowserShortcutLauncherItemController:: |
73 ~BrowserShortcutLauncherItemController() { | 74 ~BrowserShortcutLauncherItemController() { |
74 } | 75 } |
75 | 76 |
76 void BrowserShortcutLauncherItemController::UpdateBrowserItemState() { | 77 void BrowserShortcutLauncherItemController::UpdateBrowserItemState() { |
77 // Determine the new browser's active state and change if necessary. | 78 // Determine the new browser's active state and change if necessary. |
78 int browser_index = | 79 int browser_index = |
(...skipping 271 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
350 !browser->window()->IsMinimized()) { | 351 !browser->window()->IsMinimized()) { |
351 continue; | 352 continue; |
352 } | 353 } |
353 if (!IsBrowserRepresentedInBrowserList(browser) && | 354 if (!IsBrowserRepresentedInBrowserList(browser) && |
354 !browser->is_type_tabbed()) | 355 !browser->is_type_tabbed()) |
355 continue; | 356 continue; |
356 active_browsers.push_back(browser); | 357 active_browsers.push_back(browser); |
357 } | 358 } |
358 return active_browsers; | 359 return active_browsers; |
359 } | 360 } |
OLD | NEW |