| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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_SYNC_MESSAGE_FILTER_H_ | 5 #ifndef IPC_IPC_SYNC_MESSAGE_FILTER_H_ |
| 6 #define IPC_IPC_SYNC_MESSAGE_FILTER_H_ | 6 #define IPC_IPC_SYNC_MESSAGE_FILTER_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/lock.h" | |
| 11 #include "base/ref_counted.h" | 10 #include "base/ref_counted.h" |
| 11 #include "base/synchronization/lock.h" |
| 12 #include "ipc/ipc_channel_proxy.h" | 12 #include "ipc/ipc_channel_proxy.h" |
| 13 #include "ipc/ipc_sync_message.h" | 13 #include "ipc/ipc_sync_message.h" |
| 14 #include <set> | 14 #include <set> |
| 15 | 15 |
| 16 namespace base { | 16 namespace base { |
| 17 class WaitableEvent; | 17 class WaitableEvent; |
| 18 } | 18 } |
| 19 | 19 |
| 20 class MessageLoop; | 20 class MessageLoop; |
| 21 | 21 |
| (...skipping 29 matching lines...) Expand all Loading... |
| 51 // The channel to which this filter was added. | 51 // The channel to which this filter was added. |
| 52 Channel* channel_; | 52 Channel* channel_; |
| 53 | 53 |
| 54 MessageLoop* listener_loop_; // The process's main thread. | 54 MessageLoop* listener_loop_; // The process's main thread. |
| 55 MessageLoop* io_loop_; // The message loop where the Channel lives. | 55 MessageLoop* io_loop_; // The message loop where the Channel lives. |
| 56 | 56 |
| 57 typedef std::set<PendingSyncMsg*> PendingSyncMessages; | 57 typedef std::set<PendingSyncMsg*> PendingSyncMessages; |
| 58 PendingSyncMessages pending_sync_messages_; | 58 PendingSyncMessages pending_sync_messages_; |
| 59 | 59 |
| 60 // Locks data members above. | 60 // Locks data members above. |
| 61 Lock lock_; | 61 base::Lock lock_; |
| 62 | 62 |
| 63 base::WaitableEvent* shutdown_event_; | 63 base::WaitableEvent* shutdown_event_; |
| 64 | 64 |
| 65 DISALLOW_COPY_AND_ASSIGN(SyncMessageFilter); | 65 DISALLOW_COPY_AND_ASSIGN(SyncMessageFilter); |
| 66 }; | 66 }; |
| 67 | 67 |
| 68 } // namespace IPC | 68 } // namespace IPC |
| 69 | 69 |
| 70 #endif // IPC_IPC_SYNC_MESSAGE_FILTER_H_ | 70 #endif // IPC_IPC_SYNC_MESSAGE_FILTER_H_ |
| OLD | NEW |