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 "chrome/browser/chromeos/display/overscan_calibrator.h" | 5 #include "chrome/browser/chromeos/display/overscan_calibrator.h" |
6 | 6 |
7 #include <stdint.h> | 7 #include <stdint.h> |
8 | 8 |
9 #include <limits> | 9 #include <limits> |
10 | 10 |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
64 move_transform.Translate(x_offset, y_offset); | 64 move_transform.Translate(x_offset, y_offset); |
65 rotate_transform.ConcatTransform(move_transform); | 65 rotate_transform.ConcatTransform(move_transform); |
66 base_path.transform(rotate_transform.matrix(), &path); | 66 base_path.transform(rotate_transform.matrix(), &path); |
67 | 67 |
68 canvas->DrawPath(path, content_paint); | 68 canvas->DrawPath(path, content_paint); |
69 canvas->DrawPath(path, border_paint); | 69 canvas->DrawPath(path, border_paint); |
70 } | 70 } |
71 | 71 |
72 } // namespace | 72 } // namespace |
73 | 73 |
74 OverscanCalibrator::OverscanCalibrator( | 74 OverscanCalibrator::OverscanCalibrator(const display::Display& target_display, |
75 const gfx::Display& target_display, const gfx::Insets& initial_insets) | 75 const gfx::Insets& initial_insets) |
76 : display_(target_display), | 76 : display_(target_display), |
77 insets_(initial_insets), | 77 insets_(initial_insets), |
78 initial_insets_(initial_insets), | 78 initial_insets_(initial_insets), |
79 committed_(false) { | 79 committed_(false) { |
80 // Undo the overscan calibration temporarily so that the user can see | 80 // Undo the overscan calibration temporarily so that the user can see |
81 // dark boundary and current overscan region. | 81 // dark boundary and current overscan region. |
82 ash::Shell::GetInstance()->window_tree_host_manager()->SetOverscanInsets( | 82 ash::Shell::GetInstance()->window_tree_host_manager()->SetOverscanInsets( |
83 display_.id(), gfx::Insets()); | 83 display_.id(), gfx::Insets()); |
84 | 84 |
85 ash::DisplayInfo info = | 85 ash::DisplayInfo info = |
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
157 float device_scale_factor) { | 157 float device_scale_factor) { |
158 // TODO(mukai): Cancel the overscan calibration when the device | 158 // TODO(mukai): Cancel the overscan calibration when the device |
159 // configuration has changed. | 159 // configuration has changed. |
160 } | 160 } |
161 | 161 |
162 base::Closure OverscanCalibrator::PrepareForLayerBoundsChange() { | 162 base::Closure OverscanCalibrator::PrepareForLayerBoundsChange() { |
163 return base::Closure(); | 163 return base::Closure(); |
164 } | 164 } |
165 | 165 |
166 } // namespace chromeos | 166 } // namespace chromeos |
OLD | NEW |