| 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_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ |
| 6 #define CONTENT_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ | 6 #define CONTENT_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
| (...skipping 12 matching lines...) Expand all Loading... |
| 23 #include "content/public/browser/web_contents_observer.h" | 23 #include "content/public/browser/web_contents_observer.h" |
| 24 #include "content/public/common/renderer_preferences.h" | 24 #include "content/public/common/renderer_preferences.h" |
| 25 #include "url/gurl.h" | 25 #include "url/gurl.h" |
| 26 | 26 |
| 27 namespace content { | 27 namespace content { |
| 28 class NavigationEntry; | 28 class NavigationEntry; |
| 29 class NavigationControllerImpl; | 29 class NavigationControllerImpl; |
| 30 class RenderViewHostImpl; | 30 class RenderViewHostImpl; |
| 31 class RenderWidgetHostView; | 31 class RenderWidgetHostView; |
| 32 class WebContentsView; | 32 class WebContentsView; |
| 33 struct TextInputState; | |
| 34 | 33 |
| 35 enum ResourceRequestAction { | 34 enum ResourceRequestAction { |
| 36 BLOCK, | 35 BLOCK, |
| 37 RESUME, | 36 RESUME, |
| 38 CANCEL | 37 CANCEL |
| 39 }; | 38 }; |
| 40 | 39 |
| 41 class CONTENT_EXPORT InterstitialPageImpl | 40 class CONTENT_EXPORT InterstitialPageImpl |
| 42 : public NON_EXPORTED_BASE(InterstitialPage), | 41 : public NON_EXPORTED_BASE(InterstitialPage), |
| 43 public NotificationObserver, | 42 public NotificationObserver, |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 147 void ShowCreatedWidget(int route_id, const gfx::Rect& initial_rect) override; | 146 void ShowCreatedWidget(int route_id, const gfx::Rect& initial_rect) override; |
| 148 void ShowCreatedFullscreenWidget(int route_id) override; | 147 void ShowCreatedFullscreenWidget(int route_id) override; |
| 149 | 148 |
| 150 SessionStorageNamespace* GetSessionStorageNamespace( | 149 SessionStorageNamespace* GetSessionStorageNamespace( |
| 151 SiteInstance* instance) override; | 150 SiteInstance* instance) override; |
| 152 | 151 |
| 153 FrameTree* GetFrameTree() override; | 152 FrameTree* GetFrameTree() override; |
| 154 | 153 |
| 155 // RenderWidgetHostDelegate implementation: | 154 // RenderWidgetHostDelegate implementation: |
| 156 void RenderWidgetDeleted(RenderWidgetHostImpl* render_widget_host) override; | 155 void RenderWidgetDeleted(RenderWidgetHostImpl* render_widget_host) override; |
| 157 const TextInputState* GetTextInputState() override; | |
| 158 void UpdateTextInputState(RenderWidgetHostViewBase* rwhv, | |
| 159 bool text_input_state_changed) override; | |
| 160 bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, | 156 bool PreHandleKeyboardEvent(const NativeWebKeyboardEvent& event, |
| 161 bool* is_keyboard_shortcut) override; | 157 bool* is_keyboard_shortcut) override; |
| 162 void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) override; | 158 void HandleKeyboardEvent(const NativeWebKeyboardEvent& event) override; |
| 163 | 159 |
| 164 bool enabled() const { return enabled_; } | 160 bool enabled() const { return enabled_; } |
| 165 WebContents* web_contents() const; | 161 WebContents* web_contents() const; |
| 166 const GURL& url() const { return url_; } | 162 const GURL& url() const { return url_; } |
| 167 | 163 |
| 168 // Creates the WebContentsView that shows the interstitial RVH. | 164 // Creates the WebContentsView that shows the interstitial RVH. |
| 169 // Overriden in unit tests. | 165 // Overriden in unit tests. |
| (...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 292 | 288 |
| 293 // Whether the throbber should be paused. This is true from the moment the | 289 // Whether the throbber should be paused. This is true from the moment the |
| 294 // interstitial is shown until the moment the interstitial goes away or the | 290 // interstitial is shown until the moment the interstitial goes away or the |
| 295 // user chooses to proceed. | 291 // user chooses to proceed. |
| 296 bool pause_throbber_; | 292 bool pause_throbber_; |
| 297 | 293 |
| 298 scoped_ptr<InterstitialPageDelegate> delegate_; | 294 scoped_ptr<InterstitialPageDelegate> delegate_; |
| 299 | 295 |
| 300 scoped_refptr<SessionStorageNamespace> session_storage_namespace_; | 296 scoped_refptr<SessionStorageNamespace> session_storage_namespace_; |
| 301 | 297 |
| 302 scoped_ptr<TextInputState> text_input_state_; | |
| 303 | |
| 304 base::WeakPtrFactory<InterstitialPageImpl> weak_ptr_factory_; | 298 base::WeakPtrFactory<InterstitialPageImpl> weak_ptr_factory_; |
| 305 | 299 |
| 306 DISALLOW_COPY_AND_ASSIGN(InterstitialPageImpl); | 300 DISALLOW_COPY_AND_ASSIGN(InterstitialPageImpl); |
| 307 }; | 301 }; |
| 308 | 302 |
| 309 } // namespace content | 303 } // namespace content |
| 310 | 304 |
| 311 #endif // CONTENT_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ | 305 #endif // CONTENT_BROWSER_FRAME_HOST_INTERSTITIAL_PAGE_IMPL_H_ |
| OLD | NEW |