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

Side by Side Diff: ui/ozone/common/display_snapshot_proxy.cc

Issue 1636153002: Give user ability to file a feedback report from the display error notification. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: oshima's comments Created 4 years, 10 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 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/ozone/common/display_snapshot_proxy.h" 5 #include "ui/ozone/common/display_snapshot_proxy.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include "ui/ozone/common/display_mode_proxy.h" 9 #include "ui/ozone/common/display_mode_proxy.h"
10 #include "ui/ozone/common/gpu/ozone_gpu_message_params.h" 10 #include "ui/ozone/common/gpu/ozone_gpu_message_params.h"
(...skipping 19 matching lines...) Expand all
30 DisplaySnapshotProxy::DisplaySnapshotProxy(const DisplaySnapshot_Params& params) 30 DisplaySnapshotProxy::DisplaySnapshotProxy(const DisplaySnapshot_Params& params)
31 : DisplaySnapshot(params.display_id, 31 : DisplaySnapshot(params.display_id,
32 params.origin, 32 params.origin,
33 params.physical_size, 33 params.physical_size,
34 params.type, 34 params.type,
35 params.is_aspect_preserving_scaling, 35 params.is_aspect_preserving_scaling,
36 params.has_overscan, 36 params.has_overscan,
37 params.display_name, 37 params.display_name,
38 params.sys_path, 38 params.sys_path,
39 std::vector<const DisplayMode*>(), 39 std::vector<const DisplayMode*>(),
40 params.edid,
40 NULL, 41 NULL,
41 NULL), 42 NULL),
42 string_representation_(params.string_representation) { 43 string_representation_(params.string_representation) {
43 for (size_t i = 0; i < params.modes.size(); ++i) { 44 for (size_t i = 0; i < params.modes.size(); ++i) {
44 const DisplayMode_Params& mode_params = params.modes[i]; 45 const DisplayMode_Params& mode_params = params.modes[i];
45 if (IsModeBlackListed(mode_params)) 46 if (IsModeBlackListed(mode_params))
46 continue; 47 continue;
47 modes_.push_back(new DisplayModeProxy(mode_params)); 48 modes_.push_back(new DisplayModeProxy(mode_params));
48 49
49 if (params.has_current_mode && 50 if (params.has_current_mode &&
50 SameModes(params.modes[i], params.current_mode)) 51 SameModes(params.modes[i], params.current_mode))
51 current_mode_ = modes_.back(); 52 current_mode_ = modes_.back();
52 53
53 if (params.has_native_mode && 54 if (params.has_native_mode &&
54 SameModes(params.modes[i], params.native_mode)) 55 SameModes(params.modes[i], params.native_mode))
55 native_mode_ = modes_.back(); 56 native_mode_ = modes_.back();
56 } 57 }
57 58
58 product_id_ = params.product_id; 59 product_id_ = params.product_id;
59 } 60 }
60 61
61 DisplaySnapshotProxy::~DisplaySnapshotProxy() { 62 DisplaySnapshotProxy::~DisplaySnapshotProxy() {
62 } 63 }
63 64
64 std::string DisplaySnapshotProxy::ToString() const { 65 std::string DisplaySnapshotProxy::ToString() const {
65 return string_representation_; 66 return string_representation_;
66 } 67 }
67 68
68 } // namespace ui 69 } // namespace ui
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698