Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 /* | 1 /* |
| 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights | 2 * Copyright (C) 2006, 2007, 2008, 2009, 2010, 2011, 2012 Apple Inc. All rights |
| 3 * reserved. | 3 * reserved. |
| 4 * Copyright (C) 2012 Google Inc. All rights reserved. | 4 * Copyright (C) 2012 Google Inc. All rights reserved. |
| 5 * | 5 * |
| 6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
| 7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
| 8 * are met: | 8 * are met: |
| 9 * | 9 * |
| 10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 227 virtual void runScriptsAtDocumentIdle() = 0; | 227 virtual void runScriptsAtDocumentIdle() = 0; |
| 228 | 228 |
| 229 virtual void didCreateScriptContext(v8::Local<v8::Context>, int worldId) = 0; | 229 virtual void didCreateScriptContext(v8::Local<v8::Context>, int worldId) = 0; |
| 230 virtual void willReleaseScriptContext(v8::Local<v8::Context>, | 230 virtual void willReleaseScriptContext(v8::Local<v8::Context>, |
| 231 int worldId) = 0; | 231 int worldId) = 0; |
| 232 virtual bool allowScriptExtensions() = 0; | 232 virtual bool allowScriptExtensions() = 0; |
| 233 | 233 |
| 234 virtual void didChangeScrollOffset() {} | 234 virtual void didChangeScrollOffset() {} |
| 235 virtual void didUpdateCurrentHistoryItem() {} | 235 virtual void didUpdateCurrentHistoryItem() {} |
| 236 | 236 |
| 237 virtual bool allowScript(bool enabledPerSettings) { | |
| 238 return enabledPerSettings; | |
| 239 } | |
| 240 virtual bool allowScriptFromSource(bool enabledPerSettings, const KURL&) { | |
| 241 return enabledPerSettings; | |
| 242 } | |
| 243 virtual bool allowPlugins(bool enabledPerSettings) { | |
| 244 return enabledPerSettings; | |
| 245 } | |
| 246 virtual bool allowImage(bool enabledPerSettings, const KURL&) { | |
| 247 return enabledPerSettings; | |
| 248 } | |
| 249 virtual bool allowRunningInsecureContent(bool enabledPerSettings, | |
| 250 SecurityOrigin*, | |
| 251 const KURL&) { | |
| 252 return enabledPerSettings; | |
| 253 } | |
| 254 virtual bool allowAutoplay(bool defaultValue) { return defaultValue; } | |
| 255 | |
| 256 // Reports that passive mixed content was found at the provided URL. It may or | |
| 257 // may not be actually displayed later, what would be flagged by | |
| 258 // didDisplayInsecureContent. | |
| 259 virtual void passiveInsecureContentFound(const KURL&) {} | |
| 260 | |
| 261 // This callback notifies the client that the frame was about to run | |
| 262 // JavaScript but did not because allowScript returned false. We have a | |
| 263 // separate callback here because there are a number of places that need to | |
| 264 // know if JavaScript is enabled but are not necessarily preparing to execute | |
| 265 // script. | |
| 266 virtual void didNotAllowScript() {} | |
| 267 // This callback is similar, but for plugins. | |
| 268 virtual void didNotAllowPlugins() {} | |
| 269 | |
| 270 virtual WebCookieJar* cookieJar() const = 0; | 237 virtual WebCookieJar* cookieJar() const = 0; |
| 271 | 238 |
| 272 virtual void didChangeName(const String&) {} | 239 virtual void didChangeName(const String&) {} |
| 273 | 240 |
| 274 virtual void didEnforceInsecureRequestPolicy(WebInsecureRequestPolicy) {} | 241 virtual void didEnforceInsecureRequestPolicy(WebInsecureRequestPolicy) {} |
| 275 | 242 |
| 276 virtual void didUpdateToUniqueOrigin() {} | 243 virtual void didUpdateToUniqueOrigin() {} |
| 277 | 244 |
| 278 virtual void didChangeSandboxFlags(Frame* childFrame, SandboxFlags) {} | 245 virtual void didChangeSandboxFlags(Frame* childFrame, SandboxFlags) {} |
| 279 | 246 |
| (...skipping 16 matching lines...) Expand all Loading... | |
| 296 return enabledPerSettings; | 263 return enabledPerSettings; |
| 297 } | 264 } |
| 298 | 265 |
| 299 // If an HTML document is being loaded, informs the embedder that the document | 266 // If an HTML document is being loaded, informs the embedder that the document |
| 300 // will have its <body> attached soon. | 267 // will have its <body> attached soon. |
| 301 virtual void dispatchWillInsertBody() {} | 268 virtual void dispatchWillInsertBody() {} |
| 302 | 269 |
| 303 virtual std::unique_ptr<WebServiceWorkerProvider> | 270 virtual std::unique_ptr<WebServiceWorkerProvider> |
| 304 createServiceWorkerProvider() = 0; | 271 createServiceWorkerProvider() = 0; |
| 305 | 272 |
| 273 virtual ContentSettingsClient* contentSettingsClient() = 0; | |
|
dcheng
2017/04/02 05:26:19
Can we make this return a reference?
kinuko
2017/04/03 15:15:06
Done.
| |
| 274 | |
| 306 virtual SharedWorkerRepositoryClient* sharedWorkerRepositoryClient() { | 275 virtual SharedWorkerRepositoryClient* sharedWorkerRepositoryClient() { |
| 307 return 0; | 276 return 0; |
| 308 } | 277 } |
| 309 | 278 |
| 310 virtual std::unique_ptr<WebApplicationCacheHost> createApplicationCacheHost( | 279 virtual std::unique_ptr<WebApplicationCacheHost> createApplicationCacheHost( |
| 311 WebApplicationCacheHostClient*) = 0; | 280 WebApplicationCacheHostClient*) = 0; |
| 312 | 281 |
| 313 virtual void dispatchDidChangeManifest() {} | 282 virtual void dispatchDidChangeManifest() {} |
| 314 | 283 |
| 315 virtual unsigned backForwardLength() { return 0; } | 284 virtual unsigned backForwardLength() { return 0; } |
| (...skipping 27 matching lines...) Expand all Loading... | |
| 343 virtual BlameContext* frameBlameContext() { return nullptr; } | 312 virtual BlameContext* frameBlameContext() { return nullptr; } |
| 344 | 313 |
| 345 virtual void setHasReceivedUserGesture() {} | 314 virtual void setHasReceivedUserGesture() {} |
| 346 | 315 |
| 347 virtual void abortClientNavigation() {} | 316 virtual void abortClientNavigation() {} |
| 348 }; | 317 }; |
| 349 | 318 |
| 350 } // namespace blink | 319 } // namespace blink |
| 351 | 320 |
| 352 #endif // LocalFrameClient_h | 321 #endif // LocalFrameClient_h |
| OLD | NEW |