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

Side by Side Diff: content/public/common/common_param_traits.h

Issue 13529027: Switch Linux Auru ports over to POSIX SHM instead of legacy SYSV SHM. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « content/plugin/webplugin_proxy.cc ('k') | content/public/test/mock_render_process_host.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 // This file is used to define IPC::ParamTraits<> specializations for a number 5 // This file is used to define IPC::ParamTraits<> specializations for a number
6 // of types so that they can be serialized over IPC. IPC::ParamTraits<> 6 // of types so that they can be serialized over IPC. IPC::ParamTraits<>
7 // specializations for basic types (like int and std::string) and types in the 7 // specializations for basic types (like int and std::string) and types in the
8 // 'base' project can be found in ipc/ipc_message_utils.h. This file contains 8 // 'base' project can be found in ipc/ipc_message_utils.h. This file contains
9 // specializations for types that are used by the content code, and which need 9 // specializations for types that are used by the content code, and which need
10 // manual serialization code. This is usually because they're not structs with 10 // manual serialization code. This is usually because they're not structs with
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 static void Log(const param_type& p, std::string* l) { 177 static void Log(const param_type& p, std::string* l) {
178 l->append("TransportDIB("); 178 l->append("TransportDIB(");
179 LogParam(p.handle, l); 179 LogParam(p.handle, l);
180 l->append(", "); 180 l->append(", ");
181 LogParam(p.sequence_num, l); 181 LogParam(p.sequence_num, l);
182 l->append(")"); 182 l->append(")");
183 } 183 }
184 }; 184 };
185 #endif 185 #endif
186 186
187 #if defined(USE_X11) 187 #if defined(TOOLKIT_GTK)
188 template<> 188 template<>
189 struct ParamTraits<TransportDIB::Id> { 189 struct ParamTraits<TransportDIB::Id> {
190 typedef TransportDIB::Id param_type; 190 typedef TransportDIB::Id param_type;
191 static void Write(Message* m, const param_type& p) { 191 static void Write(Message* m, const param_type& p) {
192 WriteParam(m, p.shmkey); 192 WriteParam(m, p.shmkey);
193 } 193 }
194 static bool Read(const Message* m, PickleIterator* iter, param_type* r) { 194 static bool Read(const Message* m, PickleIterator* iter, param_type* r) {
195 return ReadParam(m, iter, &r->shmkey); 195 return ReadParam(m, iter, &r->shmkey);
196 } 196 }
197 static void Log(const param_type& p, std::string* l) { 197 static void Log(const param_type& p, std::string* l) {
(...skipping 12 matching lines...) Expand all
210 // Note: This function expects parameter |r| to be of type &SkBitmap since 210 // Note: This function expects parameter |r| to be of type &SkBitmap since
211 // r->SetConfig() and r->SetPixels() are called. 211 // r->SetConfig() and r->SetPixels() are called.
212 static bool Read(const Message* m, PickleIterator* iter, param_type* r); 212 static bool Read(const Message* m, PickleIterator* iter, param_type* r);
213 213
214 static void Log(const param_type& p, std::string* l); 214 static void Log(const param_type& p, std::string* l);
215 }; 215 };
216 216
217 } // namespace IPC 217 } // namespace IPC
218 218
219 #endif // CONTENT_PUBLIC_COMMON_COMMON_PARAM_TRAITS_H_ 219 #endif // CONTENT_PUBLIC_COMMON_COMMON_PARAM_TRAITS_H_
OLDNEW
« no previous file with comments | « content/plugin/webplugin_proxy.cc ('k') | content/public/test/mock_render_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698