OLD | NEW |
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 V8CrossOriginSetterInfo_h | 5 #ifndef V8CrossOriginSetterInfo_h |
6 #define V8CrossOriginSetterInfo_h | 6 #define V8CrossOriginSetterInfo_h |
7 | 7 |
| 8 #include <v8.h> |
8 #include "wtf/Allocator.h" | 9 #include "wtf/Allocator.h" |
9 #include <v8.h> | |
10 | 10 |
11 namespace blink { | 11 namespace blink { |
12 | 12 |
13 // Simple adapter that is used in place of v8::PropertyCallbackInfo for setters | 13 // Simple adapter that is used in place of v8::PropertyCallbackInfo for setters |
14 // that are accessible cross-origin. This is needed because a named access check | 14 // that are accessible cross-origin. This is needed because a named access check |
15 // interceptor takes a v8::PropertyCallbackInfo<v8::Value> argument, while a | 15 // interceptor takes a v8::PropertyCallbackInfo<v8::Value> argument, while a |
16 // normal setter interceptor takes a v8::PropertyCallbackInfo<void> argument. | 16 // normal setter interceptor takes a v8::PropertyCallbackInfo<void> argument. |
17 // | 17 // |
18 // Since the generated bindings only care about two fields (the isolate and the | 18 // Since the generated bindings only care about two fields (the isolate and the |
19 // holder), the generated bindings just substitutes this for the normal | 19 // holder), the generated bindings just substitutes this for the normal |
(...skipping 10 matching lines...) Expand all Loading... |
30 v8::Local<v8::Object> Holder() const { return m_holder; } | 30 v8::Local<v8::Object> Holder() const { return m_holder; } |
31 | 31 |
32 private: | 32 private: |
33 v8::Isolate* m_isolate; | 33 v8::Isolate* m_isolate; |
34 v8::Local<v8::Object> m_holder; | 34 v8::Local<v8::Object> m_holder; |
35 }; | 35 }; |
36 | 36 |
37 } // namespace blink | 37 } // namespace blink |
38 | 38 |
39 #endif // V8CrossOriginSetterInfo_h | 39 #endif // V8CrossOriginSetterInfo_h |
OLD | NEW |