Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(26)

Side by Side Diff: ash/launcher/launcher.cc

Issue 10027007: ash: Make sure the uber-tray popup is positioned correctly. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 8 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 "ash/focus_cycler.h" 7 #include "ash/focus_cycler.h"
8 #include "ash/launcher/launcher_delegate.h" 8 #include "ash/launcher/launcher_delegate.h"
9 #include "ash/launcher/launcher_model.h" 9 #include "ash/launcher/launcher_model.h"
10 #include "ash/launcher/launcher_view.h" 10 #include "ash/launcher/launcher_view.h"
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
158 void Launcher::SetPaintsBackground( 158 void Launcher::SetPaintsBackground(
159 bool value, 159 bool value,
160 internal::BackgroundAnimator::ChangeType change_type) { 160 internal::BackgroundAnimator::ChangeType change_type) {
161 background_animator_.SetPaintsBackground(value, change_type); 161 background_animator_.SetPaintsBackground(value, change_type);
162 } 162 }
163 163
164 void Launcher::SetStatusWidth(int width) { 164 void Launcher::SetStatusWidth(int width) {
165 delegate_view_->SetStatusWidth(width); 165 delegate_view_->SetStatusWidth(width);
166 } 166 }
167 167
168 int Launcher::GetStatusWidth() { 168 int Launcher::GetStatusWidth() const {
169 return delegate_view_->status_width(); 169 return delegate_view_->status_width();
170 } 170 }
171 171
172 gfx::Rect Launcher::GetScreenBoundsOfItemIconForWindow(aura::Window* window) { 172 gfx::Rect Launcher::GetScreenBoundsOfItemIconForWindow(aura::Window* window) {
173 if (!delegate_.get()) 173 if (!delegate_.get())
174 return gfx::Rect(); 174 return gfx::Rect();
175 175
176 LauncherID id = delegate_->GetIDByWindow(window); 176 LauncherID id = delegate_->GetIDByWindow(window);
177 gfx::Rect bounds(launcher_view_->GetIdealBoundsOfItemIcon(id)); 177 gfx::Rect bounds(launcher_view_->GetIdealBoundsOfItemIcon(id));
178 if (bounds.IsEmpty()) 178 if (bounds.IsEmpty())
(...skipping 14 matching lines...) Expand all
193 internal::LauncherView* Launcher::GetLauncherViewForTest() { 193 internal::LauncherView* Launcher::GetLauncherViewForTest() {
194 return launcher_view_; 194 return launcher_view_;
195 } 195 }
196 196
197 void Launcher::UpdateBackground(int alpha) { 197 void Launcher::UpdateBackground(int alpha) {
198 ui::Layer* layer = widget_->GetNativeView()->layer(); 198 ui::Layer* layer = widget_->GetNativeView()->layer();
199 layer->SetColor(SkColorSetARGB(alpha, 0, 0, 0)); 199 layer->SetColor(SkColorSetARGB(alpha, 0, 0, 0));
200 } 200 }
201 201
202 } // namespace ash 202 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698