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 WebLocalFrame_h | 5 #ifndef WebLocalFrame_h |
6 #define WebLocalFrame_h | 6 #define WebLocalFrame_h |
7 | 7 |
8 #include "WebCompositionUnderline.h" | 8 #include "WebCompositionUnderline.h" |
9 #include "WebFrame.h" | 9 #include "WebFrame.h" |
10 #include "WebFrameLoadType.h" | 10 #include "WebFrameLoadType.h" |
(...skipping 17 matching lines...) Expand all Loading... |
28 class WebDoubleSize; | 28 class WebDoubleSize; |
29 class WebFrameClient; | 29 class WebFrameClient; |
30 class WebFrameWidget; | 30 class WebFrameWidget; |
31 class WebInputMethodController; | 31 class WebInputMethodController; |
32 class WebRange; | 32 class WebRange; |
33 class WebScriptExecutionCallback; | 33 class WebScriptExecutionCallback; |
34 enum class WebCachePolicy; | 34 enum class WebCachePolicy; |
35 enum class WebSandboxFlags; | 35 enum class WebSandboxFlags; |
36 enum class WebTreeScopeType; | 36 enum class WebTreeScopeType; |
37 struct WebConsoleMessage; | 37 struct WebConsoleMessage; |
| 38 struct WebContentSecurityPolicyViolation; |
38 struct WebFindOptions; | 39 struct WebFindOptions; |
39 struct WebFloatRect; | 40 struct WebFloatRect; |
40 struct WebPrintPresetOptions; | 41 struct WebPrintPresetOptions; |
41 | 42 |
42 // Interface for interacting with in process frames. This contains methods that | 43 // Interface for interacting with in process frames. This contains methods that |
43 // require interacting with a frame's document. | 44 // require interacting with a frame's document. |
44 // FIXME: Move lots of methods from WebFrame in here. | 45 // FIXME: Move lots of methods from WebFrame in here. |
45 class WebLocalFrame : public WebFrame { | 46 class WebLocalFrame : public WebFrame { |
46 public: | 47 public: |
47 // Creates a WebFrame. Delete this WebFrame by calling WebFrame::close(). | 48 // Creates a WebFrame. Delete this WebFrame by calling WebFrame::close(). |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
145 bool replace = false, | 146 bool replace = false, |
146 WebFrameLoadType = WebFrameLoadType::Standard, | 147 WebFrameLoadType = WebFrameLoadType::Standard, |
147 const WebHistoryItem& = WebHistoryItem(), | 148 const WebHistoryItem& = WebHistoryItem(), |
148 WebHistoryLoadType = WebHistoryDifferentDocumentLoad, | 149 WebHistoryLoadType = WebHistoryDifferentDocumentLoad, |
149 bool isClientRedirect = false) = 0; | 150 bool isClientRedirect = false) = 0; |
150 | 151 |
151 // On load failure, attempts to make frame's parent rendering fallback content | 152 // On load failure, attempts to make frame's parent rendering fallback content |
152 // and stop this frame loading. | 153 // and stop this frame loading. |
153 virtual bool maybeRenderFallbackContent(const WebURLError&) const = 0; | 154 virtual bool maybeRenderFallbackContent(const WebURLError&) const = 0; |
154 | 155 |
| 156 // Called when a navigation is blocked because a Content Security Policy (CSP) |
| 157 // is infringed. |
| 158 virtual void contentSecurityPolicyViolation( |
| 159 const blink::WebContentSecurityPolicyViolation&) = 0; |
| 160 |
155 // Navigation State ------------------------------------------------------- | 161 // Navigation State ------------------------------------------------------- |
156 | 162 |
157 // Returns true if the current frame's load event has not completed. | 163 // Returns true if the current frame's load event has not completed. |
158 virtual bool isLoading() const = 0; | 164 virtual bool isLoading() const = 0; |
159 | 165 |
160 // Returns true if there is a pending redirect or location change | 166 // Returns true if there is a pending redirect or location change |
161 // within specified interval (in seconds). This could be caused by: | 167 // within specified interval (in seconds). This could be caused by: |
162 // * an HTTP Refresh header | 168 // * an HTTP Refresh header |
163 // * an X-Frame-Options header | 169 // * an X-Frame-Options header |
164 // * the respective http-equiv meta tags | 170 // * the respective http-equiv meta tags |
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
492 // to call these on a WebLocalFrame. | 498 // to call these on a WebLocalFrame. |
493 bool isWebLocalFrame() const override = 0; | 499 bool isWebLocalFrame() const override = 0; |
494 WebLocalFrame* toWebLocalFrame() override = 0; | 500 WebLocalFrame* toWebLocalFrame() override = 0; |
495 bool isWebRemoteFrame() const override = 0; | 501 bool isWebRemoteFrame() const override = 0; |
496 WebRemoteFrame* toWebRemoteFrame() override = 0; | 502 WebRemoteFrame* toWebRemoteFrame() override = 0; |
497 }; | 503 }; |
498 | 504 |
499 } // namespace blink | 505 } // namespace blink |
500 | 506 |
501 #endif // WebLocalFrame_h | 507 #endif // WebLocalFrame_h |
OLD | NEW |