OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
3 * Copyright (C) 2012 Ericsson AB. All rights reserved. | 3 * Copyright (C) 2012 Ericsson AB. All rights reserved. |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions are | 6 * modification, are permitted provided that the following conditions are |
7 * met: | 7 * met: |
8 * | 8 * |
9 * * Redistributions of source code must retain the above copyright | 9 * * Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 29 matching lines...) Expand all Loading... |
40 #include "bindings/v8/V8StringResource.h" | 40 #include "bindings/v8/V8StringResource.h" |
41 #include "bindings/v8/V8ThrowException.h" | 41 #include "bindings/v8/V8ThrowException.h" |
42 #include "bindings/v8/V8ValueCache.h" | 42 #include "bindings/v8/V8ValueCache.h" |
43 #include "platform/heap/Heap.h" | 43 #include "platform/heap/Heap.h" |
44 #include "wtf/MathExtras.h" | 44 #include "wtf/MathExtras.h" |
45 #include "wtf/text/AtomicString.h" | 45 #include "wtf/text/AtomicString.h" |
46 #include <v8.h> | 46 #include <v8.h> |
47 | 47 |
48 namespace WebCore { | 48 namespace WebCore { |
49 | 49 |
50 class DOMWindow; | 50 class LocalDOMWindow; |
51 class Document; | 51 class Document; |
52 class EventListener; | 52 class EventListener; |
53 class ExecutionContext; | 53 class ExecutionContext; |
54 class ExceptionState; | 54 class ExceptionState; |
55 class LocalFrame; | 55 class LocalFrame; |
56 class NodeFilter; | 56 class NodeFilter; |
57 class ScriptWrappable; | 57 class ScriptWrappable; |
58 class XPathNSResolver; | 58 class XPathNSResolver; |
59 | 59 |
60 namespace TraceEvent { | 60 namespace TraceEvent { |
(...skipping 694 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
755 } | 755 } |
756 | 756 |
757 TONATIVE_EXCEPTION(uint32_t, sequenceLength, lengthValue->Int32Value()); | 757 TONATIVE_EXCEPTION(uint32_t, sequenceLength, lengthValue->Int32Value()); |
758 length = sequenceLength; | 758 length = sequenceLength; |
759 return v8Value; | 759 return v8Value; |
760 } | 760 } |
761 | 761 |
762 v8::Isolate* toIsolate(ExecutionContext*); | 762 v8::Isolate* toIsolate(ExecutionContext*); |
763 v8::Isolate* toIsolate(LocalFrame*); | 763 v8::Isolate* toIsolate(LocalFrame*); |
764 | 764 |
765 DOMWindow* toDOMWindow(v8::Handle<v8::Value>, v8::Isolate*); | 765 LocalDOMWindow* toDOMWindow(v8::Handle<v8::Value>, v8::Isolate*); |
766 DOMWindow* toDOMWindow(v8::Handle<v8::Context>); | 766 LocalDOMWindow* toDOMWindow(v8::Handle<v8::Context>); |
767 DOMWindow* enteredDOMWindow(v8::Isolate*); | 767 LocalDOMWindow* enteredDOMWindow(v8::Isolate*); |
768 DOMWindow* currentDOMWindow(v8::Isolate*); | 768 LocalDOMWindow* currentDOMWindow(v8::Isolate*); |
769 DOMWindow* callingDOMWindow(v8::Isolate*); | 769 LocalDOMWindow* callingDOMWindow(v8::Isolate*); |
770 ExecutionContext* toExecutionContext(v8::Handle<v8::Context>); | 770 ExecutionContext* toExecutionContext(v8::Handle<v8::Context>); |
771 ExecutionContext* currentExecutionContext(v8::Isolate*); | 771 ExecutionContext* currentExecutionContext(v8::Isolate*); |
772 ExecutionContext* callingExecutionContext(v8::Isolate*); | 772 ExecutionContext* callingExecutionContext(v8::Isolate*); |
773 | 773 |
774 // Returns a V8 context associated with a ExecutionContext and a DOMWrapperWorld
. | 774 // Returns a V8 context associated with a ExecutionContext and a DOMWrapperWorld
. |
775 // This method returns an empty context if there is no frame or the frame is alr
eady detached. | 775 // This method returns an empty context if there is no frame or the frame is alr
eady detached. |
776 v8::Local<v8::Context> toV8Context(ExecutionContext*, DOMWrapperWorld&); | 776 v8::Local<v8::Context> toV8Context(ExecutionContext*, DOMWrapperWorld&); |
777 // Returns a V8 context associated with a LocalFrame and a DOMWrapperWorld. | 777 // Returns a V8 context associated with a LocalFrame and a DOMWrapperWorld. |
778 // This method returns an empty context if the frame is already detached. | 778 // This method returns an empty context if the frame is already detached. |
779 v8::Local<v8::Context> toV8Context(LocalFrame*, DOMWrapperWorld&); | 779 v8::Local<v8::Context> toV8Context(LocalFrame*, DOMWrapperWorld&); |
(...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
966 m_block.Reset(); | 966 m_block.Reset(); |
967 } | 967 } |
968 | 968 |
969 private: | 969 private: |
970 v8::TryCatch& m_block; | 970 v8::TryCatch& m_block; |
971 }; | 971 }; |
972 | 972 |
973 } // namespace WebCore | 973 } // namespace WebCore |
974 | 974 |
975 #endif // V8Binding_h | 975 #endif // V8Binding_h |
OLD | NEW |