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