| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 WebContentSettingsClient_h | 5 #ifndef WebContentSettingsClient_h |
| 6 #define WebContentSettingsClient_h | 6 #define WebContentSettingsClient_h |
| 7 | 7 |
| 8 #include "public/platform/WebContentSettingCallbacks.h" | 8 #include "public/platform/WebContentSettingCallbacks.h" |
| 9 | 9 |
| 10 namespace blink { | 10 namespace blink { |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 // Controls whether plugins are allowed for this frame. | 36 // Controls whether plugins are allowed for this frame. |
| 37 virtual bool allowPlugins(bool enabledPerSettings) { return enabledPerSettin
gs; } | 37 virtual bool allowPlugins(bool enabledPerSettings) { return enabledPerSettin
gs; } |
| 38 | 38 |
| 39 // Controls whether scripts are allowed to execute for this frame. | 39 // Controls whether scripts are allowed to execute for this frame. |
| 40 virtual bool allowScript(bool enabledPerSettings) { return enabledPerSetting
s; } | 40 virtual bool allowScript(bool enabledPerSettings) { return enabledPerSetting
s; } |
| 41 | 41 |
| 42 // Controls whether scripts loaded from the given URL are allowed to execute
for this frame. | 42 // Controls whether scripts loaded from the given URL are allowed to execute
for this frame. |
| 43 virtual bool allowScriptFromSource(bool enabledPerSettings, const WebURL& sc
riptURL) { return enabledPerSettings; } | 43 virtual bool allowScriptFromSource(bool enabledPerSettings, const WebURL& sc
riptURL) { return enabledPerSettings; } |
| 44 | 44 |
| 45 // Controls whether insecrure content is allowed to display for this frame. | 45 // Controls whether insecrure content is allowed to display for this frame. |
| 46 virtual bool allowDisplayingInsecureContent(bool enabledPerSettings, const W
ebSecurityOrigin&, const WebURL&) { return enabledPerSettings; } | 46 virtual bool allowDisplayingInsecureContent(bool enabledPerSettings, const W
ebURL&) { return enabledPerSettings; } |
| 47 | 47 |
| 48 // Controls whether insecrure scripts are allowed to execute for this frame. | 48 // Controls whether insecrure scripts are allowed to execute for this frame. |
| 49 virtual bool allowRunningInsecureContent(bool enabledPerSettings, const WebS
ecurityOrigin&, const WebURL&) { return enabledPerSettings; } | 49 virtual bool allowRunningInsecureContent(bool enabledPerSettings, const WebS
ecurityOrigin&, const WebURL&) { return enabledPerSettings; } |
| 50 | 50 |
| 51 // Controls whether the given script extension should run in a new script | 51 // Controls whether the given script extension should run in a new script |
| 52 // context in this frame. If extensionGroup is 0, the script context is the | 52 // context in this frame. If extensionGroup is 0, the script context is the |
| 53 // frame's main context. Otherwise, it is a context created by | 53 // frame's main context. Otherwise, it is a context created by |
| 54 // WebLocalFrame::executeScriptInIsolatedWorld with that same extensionGroup | 54 // WebLocalFrame::executeScriptInIsolatedWorld with that same extensionGroup |
| 55 // value. | 55 // value. |
| 56 virtual bool allowScriptExtension(const WebString& extensionName, int extens
ionGroup) { return true; } | 56 virtual bool allowScriptExtension(const WebString& extensionName, int extens
ionGroup) { return true; } |
| (...skipping 29 matching lines...) Expand all Loading... |
| 86 | 86 |
| 87 // Notifies the client that the frame instantiated a keygen element. | 87 // Notifies the client that the frame instantiated a keygen element. |
| 88 virtual void didUseKeygen() { } | 88 virtual void didUseKeygen() { } |
| 89 | 89 |
| 90 virtual ~WebContentSettingsClient() { } | 90 virtual ~WebContentSettingsClient() { } |
| 91 }; | 91 }; |
| 92 | 92 |
| 93 } // namespace blink | 93 } // namespace blink |
| 94 | 94 |
| 95 #endif // WebContentSettingsClient_h | 95 #endif // WebContentSettingsClient_h |
| OLD | NEW |