| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ | 5 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ |
| 6 #define CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ | 6 #define CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| 11 | 11 |
| 12 #include "base/callback_forward.h" | 12 #include "base/callback_forward.h" |
| 13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
| 14 #include "content/common/content_export.h" | 14 #include "content/common/content_export.h" |
| 15 #include "content/public/common/console_message_level.h" | 15 #include "content/public/common/console_message_level.h" |
| 16 #include "content/public/common/previews_state.h" |
| 16 #include "ipc/ipc_listener.h" | 17 #include "ipc/ipc_listener.h" |
| 17 #include "ipc/ipc_sender.h" | 18 #include "ipc/ipc_sender.h" |
| 18 #include "ppapi/features/features.h" | 19 #include "ppapi/features/features.h" |
| 19 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" | 20 #include "third_party/WebKit/public/platform/WebPageVisibilityState.h" |
| 20 #include "third_party/WebKit/public/web/WebNavigationPolicy.h" | 21 #include "third_party/WebKit/public/web/WebNavigationPolicy.h" |
| 21 | 22 |
| 22 namespace blink { | 23 namespace blink { |
| 23 class WebFrame; | 24 class WebFrame; |
| 24 class WebLocalFrame; | 25 class WebLocalFrame; |
| 25 class WebPlugin; | 26 class WebPlugin; |
| (...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 222 | 223 |
| 223 // Ensures that builtin mojo bindings modules are available in |context|. | 224 // Ensures that builtin mojo bindings modules are available in |context|. |
| 224 virtual void EnsureMojoBuiltinsAreAvailable( | 225 virtual void EnsureMojoBuiltinsAreAvailable( |
| 225 v8::Isolate* isolate, | 226 v8::Isolate* isolate, |
| 226 v8::Local<v8::Context> context) = 0; | 227 v8::Local<v8::Context> context) = 0; |
| 227 | 228 |
| 228 // Adds |message| to the DevTools console. | 229 // Adds |message| to the DevTools console. |
| 229 virtual void AddMessageToConsole(ConsoleMessageLevel level, | 230 virtual void AddMessageToConsole(ConsoleMessageLevel level, |
| 230 const std::string& message) = 0; | 231 const std::string& message) = 0; |
| 231 | 232 |
| 232 // Whether or not this frame is using Lo-Fi. | 233 // Returns the PreviewsState of this frame, a bitmask of potentially several |
| 233 virtual bool IsUsingLoFi() const = 0; | 234 // Previews optimizations. |
| 235 virtual PreviewsState GetPreviewsState() const = 0; |
| 234 | 236 |
| 235 // Whether or not this frame is currently pasting. | 237 // Whether or not this frame is currently pasting. |
| 236 virtual bool IsPasting() const = 0; | 238 virtual bool IsPasting() const = 0; |
| 237 | 239 |
| 238 // Returns the current visibility of the frame. | 240 // Returns the current visibility of the frame. |
| 239 virtual blink::WebPageVisibilityState GetVisibilityState() const = 0; | 241 virtual blink::WebPageVisibilityState GetVisibilityState() const = 0; |
| 240 | 242 |
| 241 // If PlzNavigate is enabled, returns true in between teh time that Blink | 243 // If PlzNavigate is enabled, returns true in between teh time that Blink |
| 242 // requests navigation until the browser responds with the result. | 244 // requests navigation until the browser responds with the result. |
| 243 virtual bool IsBrowserSideNavigationPending() = 0; | 245 virtual bool IsBrowserSideNavigationPending() = 0; |
| 244 | 246 |
| 245 protected: | 247 protected: |
| 246 ~RenderFrame() override {} | 248 ~RenderFrame() override {} |
| 247 | 249 |
| 248 private: | 250 private: |
| 249 // This interface should only be implemented inside content. | 251 // This interface should only be implemented inside content. |
| 250 friend class RenderFrameImpl; | 252 friend class RenderFrameImpl; |
| 251 RenderFrame() {} | 253 RenderFrame() {} |
| 252 }; | 254 }; |
| 253 | 255 |
| 254 } // namespace content | 256 } // namespace content |
| 255 | 257 |
| 256 #endif // CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ | 258 #endif // CONTENT_PUBLIC_RENDERER_RENDER_FRAME_H_ |
| OLD | NEW |