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

Side by Side Diff: ipc/ipc_message_utils.h

Issue 1200473003: Revert of Make SharedMemoryHandle a class on Mac. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@shared_memory_make_class3_base
Patch Set: Created 5 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 (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 #ifndef IPC_IPC_MESSAGE_UTILS_H_ 5 #ifndef IPC_IPC_MESSAGE_UTILS_H_
6 #define IPC_IPC_MESSAGE_UTILS_H_ 6 #define IPC_IPC_MESSAGE_UTILS_H_
7 7
8 #include <algorithm> 8 #include <algorithm>
9 #include <map> 9 #include <map>
10 #include <set> 10 #include <set>
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 namespace base { 50 namespace base {
51 class DictionaryValue; 51 class DictionaryValue;
52 class FilePath; 52 class FilePath;
53 class ListValue; 53 class ListValue;
54 class NullableString16; 54 class NullableString16;
55 class Time; 55 class Time;
56 class TimeDelta; 56 class TimeDelta;
57 class TimeTicks; 57 class TimeTicks;
58 class TraceTicks; 58 class TraceTicks;
59 struct FileDescriptor; 59 struct FileDescriptor;
60
61 #if defined(OS_MACOSX) && !defined(OS_IOS)
62 class SharedMemoryHandle;
63 #endif // defined(OS_MACOSX) && !defined(OS_IOS)
64 } 60 }
65 61
66 namespace IPC { 62 namespace IPC {
67 63
68 struct ChannelHandle; 64 struct ChannelHandle;
69 65
70 // ----------------------------------------------------------------------------- 66 // -----------------------------------------------------------------------------
71 // How we send IPC message logs across channels. 67 // How we send IPC message logs across channels.
72 struct IPC_EXPORT LogData { 68 struct IPC_EXPORT LogData {
73 LogData(); 69 LogData();
(...skipping 390 matching lines...) Expand 10 before | Expand all | Expand 10 after
464 struct IPC_EXPORT ParamTraits<base::FileDescriptor> { 460 struct IPC_EXPORT ParamTraits<base::FileDescriptor> {
465 typedef base::FileDescriptor param_type; 461 typedef base::FileDescriptor param_type;
466 static void Write(Message* m, const param_type& p); 462 static void Write(Message* m, const param_type& p);
467 static bool Read(const Message* m, 463 static bool Read(const Message* m,
468 base::PickleIterator* iter, 464 base::PickleIterator* iter,
469 param_type* r); 465 param_type* r);
470 static void Log(const param_type& p, std::string* l); 466 static void Log(const param_type& p, std::string* l);
471 }; 467 };
472 #endif // defined(OS_POSIX) 468 #endif // defined(OS_POSIX)
473 469
474 #if defined(OS_MACOSX) && !defined(OS_IOS)
475 template <>
476 struct IPC_EXPORT ParamTraits<base::SharedMemoryHandle> {
477 typedef base::SharedMemoryHandle param_type;
478 static void Write(Message* m, const param_type& p);
479 static bool Read(const Message* m, base::PickleIterator* iter, param_type* r);
480 static void Log(const param_type& p, std::string* l);
481 };
482 #endif
483
484 template <> 470 template <>
485 struct IPC_EXPORT ParamTraits<base::FilePath> { 471 struct IPC_EXPORT ParamTraits<base::FilePath> {
486 typedef base::FilePath param_type; 472 typedef base::FilePath param_type;
487 static void Write(Message* m, const param_type& p); 473 static void Write(Message* m, const param_type& p);
488 static bool Read(const Message* m, 474 static bool Read(const Message* m,
489 base::PickleIterator* iter, 475 base::PickleIterator* iter,
490 param_type* r); 476 param_type* r);
491 static void Log(const param_type& p, std::string* l); 477 static void Log(const param_type& p, std::string* l);
492 }; 478 };
493 479
(...skipping 516 matching lines...) Expand 10 before | Expand all | Expand 10 after
1010 template <typename... Ts> 996 template <typename... Ts>
1011 static void WriteReplyParams(Message* reply, Ts... args) { 997 static void WriteReplyParams(Message* reply, Ts... args) {
1012 ReplyParam p(args...); 998 ReplyParam p(args...);
1013 WriteParam(reply, p); 999 WriteParam(reply, p);
1014 } 1000 }
1015 }; 1001 };
1016 1002
1017 } // namespace IPC 1003 } // namespace IPC
1018 1004
1019 #endif // IPC_IPC_MESSAGE_UTILS_H_ 1005 #endif // IPC_IPC_MESSAGE_UTILS_H_
OLDNEW
« no previous file with comments | « content/browser/renderer_host/media/video_capture_buffer_pool.cc ('k') | ipc/ipc_message_utils.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698