| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 DOMWindow_h | 5 #ifndef DOMWindow_h |
| 6 #define DOMWindow_h | 6 #define DOMWindow_h |
| 7 | 7 |
| 8 #include "bindings/core/v8/Transferables.h" | 8 #include "bindings/core/v8/Transferables.h" |
| 9 #include "core/CoreExport.h" | 9 #include "core/CoreExport.h" |
| 10 #include "core/events/EventTarget.h" | 10 #include "core/events/EventTarget.h" |
| (...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 200 virtual int requestIdleCallback(IdleRequestCallback*, | 200 virtual int requestIdleCallback(IdleRequestCallback*, |
| 201 const IdleRequestOptions&) = 0; | 201 const IdleRequestOptions&) = 0; |
| 202 virtual void cancelIdleCallback(int id) = 0; | 202 virtual void cancelIdleCallback(int id) = 0; |
| 203 | 203 |
| 204 // Custom elements | 204 // Custom elements |
| 205 virtual CustomElementRegistry* customElements(ScriptState*) const = 0; | 205 virtual CustomElementRegistry* customElements(ScriptState*) const = 0; |
| 206 | 206 |
| 207 // Obsolete APIs | 207 // Obsolete APIs |
| 208 void captureEvents() {} | 208 void captureEvents() {} |
| 209 void releaseEvents() {} | 209 void releaseEvents() {} |
| 210 External* external() const; | 210 External* external(); |
| 211 | 211 |
| 212 // FIXME: This handles both window[index] and window.frames[index]. However, | 212 // FIXME: This handles both window[index] and window.frames[index]. However, |
| 213 // the spec exposes window.frames[index] across origins but not | 213 // the spec exposes window.frames[index] across origins but not |
| 214 // window[index]... | 214 // window[index]... |
| 215 DOMWindow* anonymousIndexedGetter(uint32_t) const; | 215 DOMWindow* anonymousIndexedGetter(uint32_t) const; |
| 216 | 216 |
| 217 void postMessage(PassRefPtr<SerializedScriptValue> message, | 217 void postMessage(PassRefPtr<SerializedScriptValue> message, |
| 218 const MessagePortArray&, | 218 const MessagePortArray&, |
| 219 const String& targetOrigin, | 219 const String& targetOrigin, |
| 220 LocalDOMWindow* source, | 220 LocalDOMWindow* source, |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 260 | 260 |
| 261 virtual void schedulePostMessage(MessageEvent*, | 261 virtual void schedulePostMessage(MessageEvent*, |
| 262 PassRefPtr<SecurityOrigin> target, | 262 PassRefPtr<SecurityOrigin> target, |
| 263 Document* source) = 0; | 263 Document* source) = 0; |
| 264 | 264 |
| 265 void disconnectFromFrame() { m_frame = nullptr; } | 265 void disconnectFromFrame() { m_frame = nullptr; } |
| 266 | 266 |
| 267 private: | 267 private: |
| 268 Member<Frame> m_frame; | 268 Member<Frame> m_frame; |
| 269 mutable Member<Location> m_location; | 269 mutable Member<Location> m_location; |
| 270 Member<External> m_external; |
| 270 | 271 |
| 271 // Set to true when close() has been called. Needed for | 272 // Set to true when close() has been called. Needed for |
| 272 // |window.closed| determinism; having it return 'true' | 273 // |window.closed| determinism; having it return 'true' |
| 273 // only after the layout widget's deferred window close | 274 // only after the layout widget's deferred window close |
| 274 // operation has been performed, exposes (confusing) | 275 // operation has been performed, exposes (confusing) |
| 275 // implementation details to scripts. | 276 // implementation details to scripts. |
| 276 bool m_windowIsClosing; | 277 bool m_windowIsClosing; |
| 277 | 278 |
| 278 }; | 279 }; |
| 279 | 280 |
| 280 } // namespace blink | 281 } // namespace blink |
| 281 | 282 |
| 282 #endif // DOMWindow_h | 283 #endif // DOMWindow_h |
| OLD | NEW |