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 "ash/launcher/launcher.h" | 5 #include "ash/launcher/launcher.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 | 9 |
10 #include "ash/focus_cycler.h" | 10 #include "ash/focus_cycler.h" |
(...skipping 124 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 } | 135 } |
136 | 136 |
137 void Launcher::SetVisible(bool visible) const { | 137 void Launcher::SetVisible(bool visible) const { |
138 launcher_view_->SetVisible(visible); | 138 launcher_view_->SetVisible(visible); |
139 } | 139 } |
140 | 140 |
141 bool Launcher::IsVisible() const { | 141 bool Launcher::IsVisible() const { |
142 return launcher_view_->visible(); | 142 return launcher_view_->visible(); |
143 } | 143 } |
144 | 144 |
| 145 void Launcher::SchedulePaint() { |
| 146 launcher_view_->SchedulePaintForAllButtons(); |
| 147 } |
| 148 |
145 views::View* Launcher::GetAppListButtonView() const { | 149 views::View* Launcher::GetAppListButtonView() const { |
146 return launcher_view_->GetAppListButtonView(); | 150 return launcher_view_->GetAppListButtonView(); |
147 } | 151 } |
148 | 152 |
149 void Launcher::LaunchAppIndexAt(int item_index) { | 153 void Launcher::LaunchAppIndexAt(int item_index) { |
150 LauncherModel* launcher_model = launcher_view_->model(); | 154 LauncherModel* launcher_model = launcher_view_->model(); |
151 const LauncherItems& items = launcher_model->items(); | 155 const LauncherItems& items = launcher_model->items(); |
152 int item_count = launcher_model->item_count(); | 156 int item_count = launcher_model->item_count(); |
153 int indexes_left = item_index >= 0 ? item_index : item_count; | 157 int indexes_left = item_index >= 0 ? item_index : item_count; |
154 int found_index = -1; | 158 int found_index = -1; |
(...skipping 29 matching lines...) Expand all Loading... |
184 | 188 |
185 gfx::Rect Launcher::GetLauncherViewBounds() const { | 189 gfx::Rect Launcher::GetLauncherViewBounds() const { |
186 return launcher_view_->bounds(); | 190 return launcher_view_->bounds(); |
187 } | 191 } |
188 | 192 |
189 app_list::ApplicationDragAndDropHost* Launcher::GetDragAndDropHostForAppList() { | 193 app_list::ApplicationDragAndDropHost* Launcher::GetDragAndDropHostForAppList() { |
190 return launcher_view_; | 194 return launcher_view_; |
191 } | 195 } |
192 | 196 |
193 } // namespace ash | 197 } // namespace ash |
OLD | NEW |