| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 CONTENT_COMMON_NP_CHANNEL_BASE_H_ | 5 #ifndef CONTENT_COMMON_NP_CHANNEL_BASE_H_ |
| 6 #define CONTENT_COMMON_NP_CHANNEL_BASE_H_ | 6 #define CONTENT_COMMON_NP_CHANNEL_BASE_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| 11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
| 12 #include "base/hash_tables.h" | 12 #include "base/hash_tables.h" |
| 13 #include "base/memory/ref_counted.h" | 13 #include "base/memory/ref_counted.h" |
| 14 #include "base/memory/scoped_ptr.h" | 14 #include "base/memory/scoped_ptr.h" |
| 15 #include "content/common/message_router.h" | 15 #include "content/common/message_router.h" |
| 16 #include "content/common/npobject_base.h" | 16 #include "content/common/npobject_base.h" |
| 17 #include "ipc/ipc_channel_handle.h" | 17 #include "ipc/ipc_channel_handle.h" |
| 18 #include "ipc/ipc_sync_channel.h" | 18 #include "ipc/ipc_sync_channel.h" |
| 19 #include "ui/gfx/native_widget_types.h" | 19 #include "ui/gfx/native_widget_types.h" |
| 20 | 20 |
| 21 namespace base { | 21 namespace base { |
| 22 class MessageLoopProxy; | 22 class MessageLoopProxy; |
| 23 } | 23 } |
| 24 | 24 |
| 25 #if defined(COMPILER_GCC) | 25 #if defined(COMPILER_GCC) |
| 26 namespace __gnu_cxx { | 26 namespace BASE_HASH_NAMESPACE { |
| 27 | 27 |
| 28 template<> | 28 template<> |
| 29 struct hash<NPObject*> { | 29 struct hash<NPObject*> { |
| 30 std::size_t operator()(NPObject* const& ptr) const { | 30 std::size_t operator()(NPObject* const& ptr) const { |
| 31 return hash<size_t>()(reinterpret_cast<size_t>(ptr)); | 31 return hash<size_t>()(reinterpret_cast<size_t>(ptr)); |
| 32 } | 32 } |
| 33 }; | 33 }; |
| 34 | 34 |
| 35 } // namespace __gnu_cxx | 35 } // namespace __gnu_cxx |
| 36 #elif defined(COMPILER_MSVC) | 36 #elif defined(COMPILER_MSVC) |
| (...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 193 // a result of a sync call from the renderer must unblock the renderer. We | 193 // a result of a sync call from the renderer must unblock the renderer. We |
| 194 // additionally have to do this for async messages from the renderer that | 194 // additionally have to do this for async messages from the renderer that |
| 195 // have the unblock flag set, since they could be followed by a sync message | 195 // have the unblock flag set, since they could be followed by a sync message |
| 196 // that won't get dispatched until the call to the renderer is complete. | 196 // that won't get dispatched until the call to the renderer is complete. |
| 197 bool send_unblocking_only_during_unblock_dispatch_; | 197 bool send_unblocking_only_during_unblock_dispatch_; |
| 198 | 198 |
| 199 DISALLOW_COPY_AND_ASSIGN(NPChannelBase); | 199 DISALLOW_COPY_AND_ASSIGN(NPChannelBase); |
| 200 }; | 200 }; |
| 201 | 201 |
| 202 #endif // CONTENT_COMMON_NP_CHANNEL_BASE_H_ | 202 #endif // CONTENT_COMMON_NP_CHANNEL_BASE_H_ |
| OLD | NEW |