OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ |
6 #define CONTENT_BROWSER_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ | 6 #define CONTENT_BROWSER_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ |
7 | 7 |
8 #include "base/compiler_specific.h" | 8 #include "base/compiler_specific.h" |
9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
52 virtual void Show() OVERRIDE; | 52 virtual void Show() OVERRIDE; |
53 virtual void Hide() OVERRIDE; | 53 virtual void Hide() OVERRIDE; |
54 virtual void DontProceed() OVERRIDE; | 54 virtual void DontProceed() OVERRIDE; |
55 virtual void Proceed() OVERRIDE; | 55 virtual void Proceed() OVERRIDE; |
56 virtual RenderViewHost* GetRenderViewHostForTesting() const OVERRIDE; | 56 virtual RenderViewHost* GetRenderViewHostForTesting() const OVERRIDE; |
57 virtual InterstitialPageDelegate* GetDelegateForTesting() OVERRIDE; | 57 virtual InterstitialPageDelegate* GetDelegateForTesting() OVERRIDE; |
58 virtual void DontCreateViewForTesting() OVERRIDE; | 58 virtual void DontCreateViewForTesting() OVERRIDE; |
59 virtual void SetSize(const gfx::Size& size) OVERRIDE; | 59 virtual void SetSize(const gfx::Size& size) OVERRIDE; |
60 virtual void Focus() OVERRIDE; | 60 virtual void Focus() OVERRIDE; |
61 | 61 |
62 #if defined(OS_ANDROID) | |
63 // Android shares a single view for all tabs, so we need to expose the | |
no sievers
2012/11/07 02:46:57
maybe say 'platform window' instead of 'view' here
jam
2012/11/07 17:15:42
+1, that confused me :)
nit: can you move this to
Ted C
2012/11/07 18:55:21
Done.
| |
64 // RenderViewHost to properly route gestures to the interstitial. | |
65 RenderViewHost* GetRenderViewHost() const; | |
66 #endif | |
67 | |
62 // Allows the user to navigate away by disabling the interstitial, canceling | 68 // Allows the user to navigate away by disabling the interstitial, canceling |
63 // the pending request, and unblocking the hidden renderer. The interstitial | 69 // the pending request, and unblocking the hidden renderer. The interstitial |
64 // will stay visible until the navigation completes. | 70 // will stay visible until the navigation completes. |
65 void CancelForNavigation(); | 71 void CancelForNavigation(); |
66 | 72 |
67 // Focus the first (last if reverse is true) element in the interstitial page. | 73 // Focus the first (last if reverse is true) element in the interstitial page. |
68 // Called when tab traversing. | 74 // Called when tab traversing. |
69 void FocusThroughTabTraversal(bool reverse); | 75 void FocusThroughTabTraversal(bool reverse); |
70 | 76 |
71 // See description above field. | 77 // See description above field. |
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
108 WindowOpenDisposition disposition, | 114 WindowOpenDisposition disposition, |
109 const gfx::Rect& initial_pos, | 115 const gfx::Rect& initial_pos, |
110 bool user_gesture) OVERRIDE; | 116 bool user_gesture) OVERRIDE; |
111 virtual void ShowCreatedWidget(int route_id, | 117 virtual void ShowCreatedWidget(int route_id, |
112 const gfx::Rect& initial_pos) OVERRIDE; | 118 const gfx::Rect& initial_pos) OVERRIDE; |
113 virtual void ShowCreatedFullscreenWidget(int route_id) OVERRIDE; | 119 virtual void ShowCreatedFullscreenWidget(int route_id) OVERRIDE; |
114 virtual void ShowContextMenu( | 120 virtual void ShowContextMenu( |
115 const ContextMenuParams& params, | 121 const ContextMenuParams& params, |
116 ContextMenuSourceType type) OVERRIDE; | 122 ContextMenuSourceType type) OVERRIDE; |
117 | 123 |
124 #if defined(OS_ANDROID) | |
125 virtual void AttachLayer(WebKit::WebLayer* layer) OVERRIDE; | |
126 virtual void RemoveLayer(WebKit::WebLayer* layer) OVERRIDE; | |
127 #endif | |
128 | |
118 // RenderWidgetHostDelegate implementation: | 129 // RenderWidgetHostDelegate implementation: |
119 virtual void RenderWidgetDeleted( | 130 virtual void RenderWidgetDeleted( |
120 RenderWidgetHostImpl* render_widget_host) OVERRIDE; | 131 RenderWidgetHostImpl* render_widget_host) OVERRIDE; |
121 virtual bool PreHandleKeyboardEvent( | 132 virtual bool PreHandleKeyboardEvent( |
122 const NativeWebKeyboardEvent& event, | 133 const NativeWebKeyboardEvent& event, |
123 bool* is_keyboard_shortcut) OVERRIDE; | 134 bool* is_keyboard_shortcut) OVERRIDE; |
124 virtual void HandleKeyboardEvent( | 135 virtual void HandleKeyboardEvent( |
125 const NativeWebKeyboardEvent& event) OVERRIDE; | 136 const NativeWebKeyboardEvent& event) OVERRIDE; |
126 | 137 |
127 bool enabled() const { return enabled_; } | 138 bool enabled() const { return enabled_; } |
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
217 scoped_ptr<InterstitialPageDelegate> delegate_; | 228 scoped_ptr<InterstitialPageDelegate> delegate_; |
218 | 229 |
219 base::WeakPtrFactory<InterstitialPageImpl> weak_ptr_factory_; | 230 base::WeakPtrFactory<InterstitialPageImpl> weak_ptr_factory_; |
220 | 231 |
221 DISALLOW_COPY_AND_ASSIGN(InterstitialPageImpl); | 232 DISALLOW_COPY_AND_ASSIGN(InterstitialPageImpl); |
222 }; | 233 }; |
223 | 234 |
224 } // namespace content | 235 } // namespace content |
225 | 236 |
226 #endif // CONTENT_BROWSER_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ | 237 #endif // CONTENT_BROWSER_WEB_CONTENTS_INTERSTITIAL_PAGE_IMPL_H_ |
OLD | NEW |