| 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 CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_H_ | 5 #ifndef CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_H_ |
| 6 #define CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_H_ | 6 #define CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_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/ref_counted.h" | 12 #include "base/ref_counted.h" |
| 13 #include "ipc/ipc_message.h" | 13 #include "ipc/ipc_message.h" |
| 14 | 14 |
| 15 class AutomationProvider; | 15 class AutomationProvider; |
| 16 class ExtensionMessageService; | 16 class ExtensionMessageService; |
| 17 class GURL; | 17 class GURL; |
| 18 class ListValue; | 18 class ListValue; |
| 19 class MessageLoop; | |
| 20 class RenderViewHost; | 19 class RenderViewHost; |
| 21 | 20 |
| 22 // This class represents an external port to an extension, opened | 21 // This class represents an external port to an extension, opened |
| 23 // through the automation interface. | 22 // through the automation interface. |
| 24 class ExtensionPortContainer : public IPC::Message::Sender { | 23 class ExtensionPortContainer : public IPC::Message::Sender { |
| 25 public: | 24 public: |
| 26 | 25 |
| 27 // Intercepts and processes a message posted through the automation interface. | 26 // Intercepts and processes a message posted through the automation interface. |
| 28 // Returns true if the message was intercepted. | 27 // Returns true if the message was intercepted. |
| 29 static bool InterceptMessageFromExternalHost(const std::string& message, | 28 static bool InterceptMessageFromExternalHost(const std::string& message, |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 | 78 |
| 80 // Our assigned port id. | 79 // Our assigned port id. |
| 81 int port_id_; | 80 int port_id_; |
| 82 // Handle to our associated tab. | 81 // Handle to our associated tab. |
| 83 int tab_handle_; | 82 int tab_handle_; |
| 84 | 83 |
| 85 DISALLOW_COPY_AND_ASSIGN(ExtensionPortContainer); | 84 DISALLOW_COPY_AND_ASSIGN(ExtensionPortContainer); |
| 86 }; | 85 }; |
| 87 | 86 |
| 88 #endif // CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_H_ | 87 #endif // CHROME_BROWSER_AUTOMATION_EXTENSION_PORT_CONTAINER_H_ |
| OLD | NEW |