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

Side by Side Diff: remoting/host/chromoting_param_traits.h

Issue 2933203002: [Chromoting] Use ProcessStatsSender in DesktopSessionAgent (desktop process) (Closed)
Patch Set: Resolve review comments Created 3 years, 6 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_ 5 #ifndef REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_
6 #define REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_ 6 #define REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_
7 7
8 #include "ipc/ipc_message.h" 8 #include "ipc/ipc_message.h"
9 #include "ipc/ipc_param_traits.h" 9 #include "ipc/ipc_param_traits.h"
10 #include "net/base/ip_address.h" 10 #include "net/base/ip_address.h"
11 #include "net/base/ip_endpoint.h" 11 #include "net/base/ip_endpoint.h"
12 #include "remoting/host/desktop_environment_options.h" 12 #include "remoting/host/desktop_environment_options.h"
13 #include "remoting/host/screen_resolution.h" 13 #include "remoting/host/screen_resolution.h"
14 #include "remoting/proto/process_stats.pb.h"
14 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h" 15 #include "third_party/webrtc/modules/desktop_capture/desktop_frame.h"
15 #include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h" 16 #include "third_party/webrtc/modules/desktop_capture/desktop_geometry.h"
16 #include "third_party/webrtc/modules/desktop_capture/mouse_cursor.h" 17 #include "third_party/webrtc/modules/desktop_capture/mouse_cursor.h"
17 18
18 namespace IPC { 19 namespace IPC {
19 20
20 template <> 21 template <>
21 struct ParamTraits<webrtc::DesktopVector> { 22 struct ParamTraits<webrtc::DesktopVector> {
22 typedef webrtc::DesktopVector param_type; 23 typedef webrtc::DesktopVector param_type;
23 static void GetSize(base::PickleSizer* s, const param_type& p); 24 static void GetSize(base::PickleSizer* s, const param_type& p);
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
84 template <> 85 template <>
85 struct ParamTraits<remoting::DesktopEnvironmentOptions> { 86 struct ParamTraits<remoting::DesktopEnvironmentOptions> {
86 typedef remoting::DesktopEnvironmentOptions param_type; 87 typedef remoting::DesktopEnvironmentOptions param_type;
87 static void Write(base::Pickle* m, const param_type& p); 88 static void Write(base::Pickle* m, const param_type& p);
88 static bool Read(const base::Pickle* m, 89 static bool Read(const base::Pickle* m,
89 base::PickleIterator* iter, 90 base::PickleIterator* iter,
90 param_type* p); 91 param_type* p);
91 static void Log(const param_type& p, std::string* l); 92 static void Log(const param_type& p, std::string* l);
92 }; 93 };
93 94
95 // Serializes and deserializes AggregatedProcessResourceUsage. This ParamTraits
96 // specialization does not handle AggregatedProcessResourceUsage::usages().
97 template <>
98 struct ParamTraits<remoting::protocol::AggregatedProcessResourceUsage> {
99 typedef remoting::protocol::AggregatedProcessResourceUsage param_type;
100 static void Write(base::Pickle* m, const param_type& p);
101 static bool Read(const base::Pickle* m,
102 base::PickleIterator* iter,
103 param_type* p);
104 static void Log(const param_type& p, std::string* l);
105 };
106
94 } // namespace IPC 107 } // namespace IPC
95 108
96 #endif // REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_ 109 #endif // REMOTING_HOST_CHROMOTING_PARAM_TRAITS_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698