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

Side by Side Diff: ui/gfx/display.cc

Issue 922843002: Fix software mirror mode on Ozone part 2/2 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 9 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 "ui/gfx/display.h" 5 #include "ui/gfx/display.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 bool Display::HasForceDeviceScaleFactor() { 53 bool Display::HasForceDeviceScaleFactor() {
54 static const bool kHasForceDeviceScaleFactor = 54 static const bool kHasForceDeviceScaleFactor =
55 HasForceDeviceScaleFactorImpl(); 55 HasForceDeviceScaleFactorImpl();
56 return kHasForceDeviceScaleFactor; 56 return kHasForceDeviceScaleFactor;
57 } 57 }
58 58
59 Display::Display() 59 Display::Display()
60 : id_(kInvalidDisplayID), 60 : id_(kInvalidDisplayID),
61 device_scale_factor_(GetForcedDeviceScaleFactor()), 61 device_scale_factor_(GetForcedDeviceScaleFactor()),
62 rotation_(ROTATE_0), 62 rotation_(ROTATE_0),
63 touch_support_(TOUCH_SUPPORT_UNKNOWN) { 63 touch_support_(TOUCH_SUPPORT_UNKNOWN),
64 mirrored_display_id_(kInvalidDisplayID) {
64 } 65 }
65 66
66 Display::Display(int64 id) 67 Display::Display(int64 id)
67 : id_(id), 68 : id_(id),
68 device_scale_factor_(GetForcedDeviceScaleFactor()), 69 device_scale_factor_(GetForcedDeviceScaleFactor()),
69 rotation_(ROTATE_0), 70 rotation_(ROTATE_0),
70 touch_support_(TOUCH_SUPPORT_UNKNOWN) { 71 touch_support_(TOUCH_SUPPORT_UNKNOWN),
72 mirrored_display_id_(kInvalidDisplayID) {
71 } 73 }
72 74
73 Display::Display(int64 id, const gfx::Rect& bounds) 75 Display::Display(int64 id, const gfx::Rect& bounds)
74 : id_(id), 76 : id_(id),
75 bounds_(bounds), 77 bounds_(bounds),
76 work_area_(bounds), 78 work_area_(bounds),
77 device_scale_factor_(GetForcedDeviceScaleFactor()), 79 device_scale_factor_(GetForcedDeviceScaleFactor()),
78 rotation_(ROTATE_0), 80 rotation_(ROTATE_0),
79 touch_support_(TOUCH_SUPPORT_UNKNOWN) { 81 touch_support_(TOUCH_SUPPORT_UNKNOWN) {
80 #if defined(USE_AURA) 82 #if defined(USE_AURA)
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
184 186
185 int64 Display::InternalDisplayId() { 187 int64 Display::InternalDisplayId() {
186 return internal_display_id_; 188 return internal_display_id_;
187 } 189 }
188 190
189 void Display::SetInternalDisplayId(int64 internal_display_id) { 191 void Display::SetInternalDisplayId(int64 internal_display_id) {
190 internal_display_id_ = internal_display_id; 192 internal_display_id_ = internal_display_id;
191 } 193 }
192 194
193 } // namespace gfx 195 } // namespace gfx
OLDNEW
« ui/gfx/display.h ('K') | « ui/gfx/display.h ('k') | ui/ozone/platform/dri/dri_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698