OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights
reserved. |
3 * Copyright (C) 2012 Google Inc. All rights reserved. | 3 * Copyright (C) 2012 Google Inc. 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 | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * | 8 * |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. 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 30 matching lines...) Expand all Loading... |
41 #include "core/loader/NavigationPolicy.h" | 41 #include "core/loader/NavigationPolicy.h" |
42 #include "platform/heap/Handle.h" | 42 #include "platform/heap/Handle.h" |
43 #include "platform/network/ContentSecurityPolicyParsers.h" | 43 #include "platform/network/ContentSecurityPolicyParsers.h" |
44 #include "platform/network/ResourceLoadPriority.h" | 44 #include "platform/network/ResourceLoadPriority.h" |
45 #include "platform/weborigin/Referrer.h" | 45 #include "platform/weborigin/Referrer.h" |
46 #include "public/platform/WebEffectiveConnectionType.h" | 46 #include "public/platform/WebEffectiveConnectionType.h" |
47 #include "public/platform/WebInsecureRequestPolicy.h" | 47 #include "public/platform/WebInsecureRequestPolicy.h" |
48 #include "public/platform/WebLoadingBehaviorFlag.h" | 48 #include "public/platform/WebLoadingBehaviorFlag.h" |
49 #include "wtf/Forward.h" | 49 #include "wtf/Forward.h" |
50 #include "wtf/Vector.h" | 50 #include "wtf/Vector.h" |
51 #include <memory> | |
52 #include <v8.h> | 51 #include <v8.h> |
53 | 52 |
54 namespace blink { | 53 namespace blink { |
55 | 54 |
56 class Document; | 55 class Document; |
57 class DocumentLoader; | 56 class DocumentLoader; |
58 class FetchRequest; | 57 class FetchRequest; |
59 struct FrameLoadRequest; | 58 struct FrameLoadRequest; |
60 class HTMLFormElement; | 59 class HTMLFormElement; |
61 class HTMLFrameElementBase; | 60 class HTMLFrameElementBase; |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
168 | 167 |
169 virtual LocalFrame* createFrame(const FrameLoadRequest&, const AtomicString&
name, HTMLFrameOwnerElement*) = 0; | 168 virtual LocalFrame* createFrame(const FrameLoadRequest&, const AtomicString&
name, HTMLFrameOwnerElement*) = 0; |
170 // Whether or not plugin creation should fail if the HTMLPlugInElement isn't
in the DOM after plugin initialization. | 169 // Whether or not plugin creation should fail if the HTMLPlugInElement isn't
in the DOM after plugin initialization. |
171 enum DetachedPluginPolicy { | 170 enum DetachedPluginPolicy { |
172 FailOnDetachedPlugin, | 171 FailOnDetachedPlugin, |
173 AllowDetachedPlugin, | 172 AllowDetachedPlugin, |
174 }; | 173 }; |
175 virtual bool canCreatePluginWithoutRenderer(const String& mimeType) const =
0; | 174 virtual bool canCreatePluginWithoutRenderer(const String& mimeType) const =
0; |
176 virtual Widget* createPlugin(HTMLPlugInElement*, const KURL&, const Vector<S
tring>&, const Vector<String>&, const String&, bool loadManually, DetachedPlugin
Policy) = 0; | 175 virtual Widget* createPlugin(HTMLPlugInElement*, const KURL&, const Vector<S
tring>&, const Vector<String>&, const String&, bool loadManually, DetachedPlugin
Policy) = 0; |
177 | 176 |
178 virtual std::unique_ptr<WebMediaPlayer> createWebMediaPlayer(HTMLMediaElemen
t&, const WebMediaPlayerSource&, WebMediaPlayerClient*) = 0; | 177 virtual PassOwnPtr<WebMediaPlayer> createWebMediaPlayer(HTMLMediaElement&, c
onst WebMediaPlayerSource&, WebMediaPlayerClient*) = 0; |
179 | 178 |
180 virtual std::unique_ptr<WebMediaSession> createWebMediaSession() = 0; | 179 virtual PassOwnPtr<WebMediaSession> createWebMediaSession() = 0; |
181 | 180 |
182 virtual ObjectContentType getObjectContentType(const KURL&, const String& mi
meType, bool shouldPreferPlugInsForImages) = 0; | 181 virtual ObjectContentType getObjectContentType(const KURL&, const String& mi
meType, bool shouldPreferPlugInsForImages) = 0; |
183 | 182 |
184 virtual void didCreateNewDocument() = 0; | 183 virtual void didCreateNewDocument() = 0; |
185 virtual void dispatchDidClearWindowObjectInMainWorld() = 0; | 184 virtual void dispatchDidClearWindowObjectInMainWorld() = 0; |
186 virtual void documentElementAvailable() = 0; | 185 virtual void documentElementAvailable() = 0; |
187 virtual void runScriptsAtDocumentElementAvailable() = 0; | 186 virtual void runScriptsAtDocumentElementAvailable() = 0; |
188 virtual void runScriptsAtDocumentReady(bool documentIsEmpty) = 0; | 187 virtual void runScriptsAtDocumentReady(bool documentIsEmpty) = 0; |
189 | 188 |
190 virtual void didCreateScriptContext(v8::Local<v8::Context>, int extensionGro
up, int worldId) = 0; | 189 virtual void didCreateScriptContext(v8::Local<v8::Context>, int extensionGro
up, int worldId) = 0; |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
237 | 236 |
238 virtual void dispatchWillStartUsingPeerConnectionHandler(WebRTCPeerConnectio
nHandler*) { } | 237 virtual void dispatchWillStartUsingPeerConnectionHandler(WebRTCPeerConnectio
nHandler*) { } |
239 | 238 |
240 virtual bool allowWebGL(bool enabledPerSettings) { return enabledPerSettings
; } | 239 virtual bool allowWebGL(bool enabledPerSettings) { return enabledPerSettings
; } |
241 | 240 |
242 // If an HTML document is being loaded, informs the embedder that the docume
nt will have its <body> attached soon. | 241 // If an HTML document is being loaded, informs the embedder that the docume
nt will have its <body> attached soon. |
243 virtual void dispatchWillInsertBody() { } | 242 virtual void dispatchWillInsertBody() { } |
244 | 243 |
245 virtual void dispatchDidChangeResourcePriority(unsigned long identifier, Res
ourceLoadPriority, int intraPriorityValue) { } | 244 virtual void dispatchDidChangeResourcePriority(unsigned long identifier, Res
ourceLoadPriority, int intraPriorityValue) { } |
246 | 245 |
247 virtual std::unique_ptr<WebServiceWorkerProvider> createServiceWorkerProvide
r() = 0; | 246 virtual PassOwnPtr<WebServiceWorkerProvider> createServiceWorkerProvider() =
0; |
248 | 247 |
249 virtual bool isControlledByServiceWorker(DocumentLoader&) = 0; | 248 virtual bool isControlledByServiceWorker(DocumentLoader&) = 0; |
250 | 249 |
251 virtual int64_t serviceWorkerID(DocumentLoader&) = 0; | 250 virtual int64_t serviceWorkerID(DocumentLoader&) = 0; |
252 | 251 |
253 virtual SharedWorkerRepositoryClient* sharedWorkerRepositoryClient() { retur
n 0; } | 252 virtual SharedWorkerRepositoryClient* sharedWorkerRepositoryClient() { retur
n 0; } |
254 | 253 |
255 virtual std::unique_ptr<WebApplicationCacheHost> createApplicationCacheHost(
WebApplicationCacheHostClient*) = 0; | 254 virtual PassOwnPtr<WebApplicationCacheHost> createApplicationCacheHost(WebAp
plicationCacheHostClient*) = 0; |
256 | 255 |
257 virtual void dispatchDidChangeManifest() { } | 256 virtual void dispatchDidChangeManifest() { } |
258 | 257 |
259 virtual unsigned backForwardLength() { return 0; } | 258 virtual unsigned backForwardLength() { return 0; } |
260 | 259 |
261 virtual bool isFrameLoaderClientImpl() const { return false; } | 260 virtual bool isFrameLoaderClientImpl() const { return false; } |
262 | 261 |
263 // Called when elements preventing the sudden termination of the frame | 262 // Called when elements preventing the sudden termination of the frame |
264 // become present or stop being present. |type| is the type of element | 263 // become present or stop being present. |type| is the type of element |
265 // (BeforeUnload handler, Unload handler). | 264 // (BeforeUnload handler, Unload handler). |
266 enum SuddenTerminationDisablerType { | 265 enum SuddenTerminationDisablerType { |
267 BeforeUnloadHandler, | 266 BeforeUnloadHandler, |
268 UnloadHandler, | 267 UnloadHandler, |
269 }; | 268 }; |
270 virtual void suddenTerminationDisablerChanged(bool present, SuddenTerminatio
nDisablerType) { } | 269 virtual void suddenTerminationDisablerChanged(bool present, SuddenTerminatio
nDisablerType) { } |
271 | 270 |
272 virtual LinkResource* createServiceWorkerLinkResource(HTMLLinkElement*) { re
turn nullptr; } | 271 virtual LinkResource* createServiceWorkerLinkResource(HTMLLinkElement*) { re
turn nullptr; } |
273 | 272 |
274 // Effective connection type when this frame was loaded. | 273 // Effective connection type when this frame was loaded. |
275 virtual WebEffectiveConnectionType getEffectiveConnectionType() { return Web
EffectiveConnectionType::TypeUnknown; } | 274 virtual WebEffectiveConnectionType getEffectiveConnectionType() { return Web
EffectiveConnectionType::TypeUnknown; } |
276 }; | 275 }; |
277 | 276 |
278 } // namespace blink | 277 } // namespace blink |
279 | 278 |
280 #endif // FrameLoaderClient_h | 279 #endif // FrameLoaderClient_h |
OLD | NEW |