| OLD | NEW |
| 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 "ui/display/chromeos/x11/display_snapshot_x11.h" | 5 #include "ui/display/chromeos/x11/display_snapshot_x11.h" |
| 6 | 6 |
| 7 #include "base/strings/stringprintf.h" | 7 #include "base/strings/stringprintf.h" |
| 8 #include "ui/display/chromeos/x11/display_mode_x11.h" | 8 #include "ui/display/chromeos/x11/display_mode_x11.h" |
| 9 | 9 |
| 10 namespace ui { | 10 namespace ui { |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 const DisplayMode* native_mode, | 23 const DisplayMode* native_mode, |
| 24 RROutput output, | 24 RROutput output, |
| 25 RRCrtc crtc, | 25 RRCrtc crtc, |
| 26 int index) | 26 int index) |
| 27 : DisplaySnapshot(display_id, | 27 : DisplaySnapshot(display_id, |
| 28 origin, | 28 origin, |
| 29 physical_size, | 29 physical_size, |
| 30 type, | 30 type, |
| 31 is_aspect_preserving_scaling, | 31 is_aspect_preserving_scaling, |
| 32 has_overscan, | 32 has_overscan, |
| 33 false, |
| 33 display_name, | 34 display_name, |
| 34 // TODO(jdufault): Figure out if we can get the file | 35 // TODO(jdufault): Figure out if we can get the file |
| 35 // descriptor that maps to the device. | 36 // descriptor that maps to the device. |
| 36 base::FilePath(), | 37 base::FilePath(), |
| 37 modes, | 38 modes, |
| 38 edid, | 39 edid, |
| 39 current_mode, | 40 current_mode, |
| 40 native_mode), | 41 native_mode), |
| 41 output_(output), | 42 output_(output), |
| 42 crtc_(crtc), | 43 crtc_(crtc), |
| 43 index_(index) {} | 44 index_(index) {} |
| 44 | 45 |
| 45 DisplaySnapshotX11::~DisplaySnapshotX11() {} | 46 DisplaySnapshotX11::~DisplaySnapshotX11() {} |
| 46 | 47 |
| 47 std::string DisplaySnapshotX11::ToString() const { | 48 std::string DisplaySnapshotX11::ToString() const { |
| 48 return base::StringPrintf( | 49 return base::StringPrintf( |
| 49 "[type=%d, output=%ld, crtc=%ld, mode=%ld, dim=%dx%d]", | 50 "[type=%d, output=%ld, crtc=%ld, mode=%ld, dim=%dx%d]", |
| 50 type_, | 51 type_, |
| 51 output_, | 52 output_, |
| 52 crtc_, | 53 crtc_, |
| 53 current_mode_ | 54 current_mode_ |
| 54 ? static_cast<const DisplayModeX11*>(current_mode_)->mode_id() | 55 ? static_cast<const DisplayModeX11*>(current_mode_)->mode_id() |
| 55 : 0, | 56 : 0, |
| 56 physical_size_.width(), | 57 physical_size_.width(), |
| 57 physical_size_.height()); | 58 physical_size_.height()); |
| 58 } | 59 } |
| 59 | 60 |
| 60 } // namespace ui | 61 } // namespace ui |
| OLD | NEW |