| 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 CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ | 5 #ifndef CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ |
| 6 #define CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ | 6 #define CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_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 "v8/include/v8.h" | 12 #include "v8/include/v8.h" |
| 13 | 13 |
| 14 namespace WebKit { | 14 namespace WebKit { |
| 15 class WebFrame; | 15 class WebFrame; |
| 16 } | 16 } |
| 17 | 17 |
| 18 namespace base { | |
| 19 class ListValue; | |
| 20 } | |
| 21 | |
| 22 namespace content { | 18 namespace content { |
| 23 class RenderView; | 19 class RenderView; |
| 24 } | 20 } |
| 25 | 21 |
| 26 // Chrome's wrapper for a v8 context. | 22 // Chrome's wrapper for a v8 context. |
| 27 // | 23 // |
| 28 // TODO(aa): Consider converting this back to a set of bindings_utils. It would | 24 // TODO(aa): Consider converting this back to a set of bindings_utils. It would |
| 29 // require adding WebFrame::GetIsolatedWorldIdByV8Context() to WebCore, but then | 25 // require adding WebFrame::GetIsolatedWorldIdByV8Context() to WebCore, but then |
| 30 // we won't need this object and it's a bit less state to keep track of. | 26 // we won't need this object and it's a bit less state to keep track of. |
| 31 class ChromeV8Context { | 27 class ChromeV8Context { |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 // object can outlive is destroyed asynchronously. | 80 // object can outlive is destroyed asynchronously. |
| 85 WebKit::WebFrame* web_frame_; | 81 WebKit::WebFrame* web_frame_; |
| 86 | 82 |
| 87 // The extension ID this context is associated with. | 83 // The extension ID this context is associated with. |
| 88 std::string extension_id_; | 84 std::string extension_id_; |
| 89 | 85 |
| 90 DISALLOW_COPY_AND_ASSIGN(ChromeV8Context); | 86 DISALLOW_COPY_AND_ASSIGN(ChromeV8Context); |
| 91 }; | 87 }; |
| 92 | 88 |
| 93 #endif // CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ | 89 #endif // CHROME_RENDERER_EXTENSIONS_CHROME_V8_CONTEXT_H_ |
| OLD | NEW |