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

Side by Side Diff: ash/common/wm/window_cycle_list.cc

Issue 2640983002: Rename paint data structures (Closed)
Patch Set: Rebase Created 3 years, 11 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/common/wm/window_cycle_list.h" 5 #include "ash/common/wm/window_cycle_list.h"
6 6
7 #include <list> 7 #include <list>
8 #include <map> 8 #include <map>
9 9
10 #include "ash/common/wm/mru_window_tracker.h" 10 #include "ash/common/wm/mru_window_tracker.h"
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 // changes other animatable properties. 345 // changes other animatable properties.
346 highlight_view_->layer()->SetAnimator( 346 highlight_view_->layer()->SetAnimator(
347 ui::LayerAnimator::CreateImplicitAnimator()); 347 ui::LayerAnimator::CreateImplicitAnimator());
348 } 348 }
349 } 349 }
350 350
351 void OnPaintBackground(gfx::Canvas* canvas) override { 351 void OnPaintBackground(gfx::Canvas* canvas) override {
352 // We can't set a bg on the mirror container itself because the highlight 352 // We can't set a bg on the mirror container itself because the highlight
353 // view needs to be on top of the bg but behind the target windows. 353 // view needs to be on top of the bg but behind the target windows.
354 const gfx::RectF shield_bounds(mirror_container_->bounds()); 354 const gfx::RectF shield_bounds(mirror_container_->bounds());
355 SkPaint paint; 355 cc::PaintFlags paint;
356 paint.setColor(SkColorSetA(SK_ColorBLACK, 0xE6)); 356 paint.setColor(SkColorSetA(SK_ColorBLACK, 0xE6));
357 paint.setStyle(SkPaint::kFill_Style); 357 paint.setStyle(cc::PaintFlags::kFill_Style);
358 float corner_radius = 0.f; 358 float corner_radius = 0.f;
359 if (shield_bounds.width() < width()) { 359 if (shield_bounds.width() < width()) {
360 paint.setAntiAlias(true); 360 paint.setAntiAlias(true);
361 corner_radius = kBackgroundCornerRadius; 361 corner_radius = kBackgroundCornerRadius;
362 } 362 }
363 canvas->DrawRoundRect(shield_bounds, corner_radius, paint); 363 canvas->DrawRoundRect(shield_bounds, corner_radius, paint);
364 } 364 }
365 365
366 View* GetInitiallyFocusedView() override { 366 View* GetInitiallyFocusedView() override {
367 return window_view_map_[target_window_]; 367 return window_view_map_[target_window_];
(...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after
539 widget_rect.set_height(widget_height); 539 widget_rect.set_height(widget_height);
540 params.bounds = widget_rect; 540 params.bounds = widget_rect;
541 widget->Init(params); 541 widget->Init(params);
542 542
543 screen_observer_.Add(display::Screen::GetScreen()); 543 screen_observer_.Add(display::Screen::GetScreen());
544 widget->Show(); 544 widget->Show();
545 cycle_ui_widget_ = widget; 545 cycle_ui_widget_ = widget;
546 } 546 }
547 547
548 } // namespace ash 548 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698