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

Side by Side Diff: ash/magnifier/partial_magnification_controller.cc

Issue 2661353002: ui/gfx: split out code that depends on paint (Closed)
Patch Set: Fix mac, chromeos build Created 3 years, 10 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 (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/magnifier/partial_magnification_controller.h" 5 #include "ash/magnifier/partial_magnification_controller.h"
6 6
7 #include "ash/common/system/chromeos/palette/palette_utils.h" 7 #include "ash/common/system/chromeos/palette/palette_utils.h"
8 #include "ash/shell.h" 8 #include "ash/shell.h"
9 #include "third_party/skia/include/core/SkDrawLooper.h" 9 #include "third_party/skia/include/core/SkDrawLooper.h"
10 #include "ui/aura/window_event_dispatcher.h" 10 #include "ui/aura/window_event_dispatcher.h"
11 #include "ui/aura/window_tree_host.h" 11 #include "ui/aura/window_tree_host.h"
12 #include "ui/compositor/layer.h" 12 #include "ui/compositor/layer.h"
13 #include "ui/compositor/paint_recorder.h" 13 #include "ui/compositor/paint_recorder.h"
14 #include "ui/events/event.h" 14 #include "ui/events/event.h"
15 #include "ui/events/event_constants.h" 15 #include "ui/events/event_constants.h"
16 #include "ui/gfx/shadow_value.h" 16 #include "ui/gfx/shadow_value.h"
17 #include "ui/gfx/skia_paint_util.h"
17 #include "ui/views/widget/widget.h" 18 #include "ui/views/widget/widget.h"
18 #include "ui/wm/core/coordinate_conversion.h" 19 #include "ui/wm/core/coordinate_conversion.h"
19 20
20 namespace ash { 21 namespace ash {
21 namespace { 22 namespace {
22 23
23 // Ratio of magnifier scale. 24 // Ratio of magnifier scale.
24 const float kMagnificationScale = 2.f; 25 const float kMagnificationScale = 2.f;
25 // Radius of the magnifying glass in DIP. This does not include the thickness 26 // Radius of the magnifying glass in DIP. This does not include the thickness
26 // of the magnifying glass shadow and border. 27 // of the magnifying glass shadow and border.
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 372
372 void PartialMagnificationController::RemoveZoomWidgetObservers() { 373 void PartialMagnificationController::RemoveZoomWidgetObservers() {
373 DCHECK(host_widget_); 374 DCHECK(host_widget_);
374 host_widget_->RemoveObserver(this); 375 host_widget_->RemoveObserver(this);
375 aura::Window* root_window = host_widget_->GetNativeView()->GetRootWindow(); 376 aura::Window* root_window = host_widget_->GetNativeView()->GetRootWindow();
376 DCHECK(root_window); 377 DCHECK(root_window);
377 root_window->RemoveObserver(this); 378 root_window->RemoveObserver(this);
378 } 379 }
379 380
380 } // namespace ash 381 } // namespace ash
OLDNEW
« no previous file with comments | « ash/common/system/tray/tray_details_view.cc ('k') | chrome/browser/ui/views/infobars/infobar_container_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698