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.
5 #include "ui/display/chromeos/x11/display_snapshot_x11.h"
7 #include "base/strings/stringprintf.h"
8 #include "ui/display/chromeos/x11/display_mode_x11.h"
12 DisplaySnapshotX11::DisplaySnapshotX11(
14 const gfx::Point
& origin
,
15 const gfx::Size
& physical_size
,
16 DisplayConnectionType type
,
17 bool is_aspect_preserving_scaling
,
19 std::string display_name
,
20 const std::vector
<const DisplayMode
*>& modes
,
21 const DisplayMode
* current_mode
,
22 const DisplayMode
* native_mode
,
26 : DisplaySnapshot(display_id
,
30 is_aspect_preserving_scaling
,
40 DisplaySnapshotX11::~DisplaySnapshotX11() {}
42 std::string
DisplaySnapshotX11::ToString() const {
43 return base::StringPrintf(
44 "[type=%d, output=%ld, crtc=%ld, mode=%ld, dim=%dx%d]",
49 ? static_cast<const DisplayModeX11
*>(current_mode_
)->mode_id()
51 physical_size_
.width(),
52 physical_size_
.height());