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_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ |
6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 6 #define CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ |
7 | 7 |
8 #include <deque> | 8 #include <deque> |
9 #include <list> | 9 #include <list> |
10 #include <map> | 10 #include <map> |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
221 virtual void WasShown(const ui::LatencyInfo& latency_info); | 221 virtual void WasShown(const ui::LatencyInfo& latency_info); |
222 | 222 |
223 // Returns true if the RenderWidget is hidden. | 223 // Returns true if the RenderWidget is hidden. |
224 bool is_hidden() const { return is_hidden_; } | 224 bool is_hidden() const { return is_hidden_; } |
225 | 225 |
226 // Called to notify the RenderWidget that its associated native window | 226 // Called to notify the RenderWidget that its associated native window |
227 // got/lost focused. | 227 // got/lost focused. |
228 virtual void GotFocus(); | 228 virtual void GotFocus(); |
229 virtual void LostCapture(); | 229 virtual void LostCapture(); |
230 | 230 |
231 // Indicates whether the RenderWidgetHost is focused. | |
Charlie Reis
2015/02/04 17:32:43
nit: thinks it is focused.
mlamouri (slow - plz ping)
2015/02/04 17:44:11
Done.
| |
232 // This is different from RenderWidgetHostView in the sense that it reflects | |
Charlie Reis
2015/02/04 17:32:43
nit: RenderWidgetHostView::HasFocus()
mlamouri (slow - plz ping)
2015/02/04 17:44:11
Done.
| |
233 // what the renderer process knows - it saves the state that is sent/received. | |
Charlie Reis
2015/02/04 17:32:43
nit: colon rather than dash
mlamouri (slow - plz ping)
2015/02/04 17:44:12
Done.
| |
234 // RenderWidgetHostView::HasFocus() is checking whether the view is focused so | |
235 // it is possible in some edge cases that a view was requested to be focused | |
Charlie Reis
2015/02/04 17:32:43
nit: requested to be focused but it failed, thus H
mlamouri (slow - plz ping)
2015/02/04 17:44:12
Done.
| |
236 // but HasFocus() returns false. | |
237 bool is_focused() const { return is_focused_; } | |
238 | |
231 // Called to notify the RenderWidget that it has lost the mouse lock. | 239 // Called to notify the RenderWidget that it has lost the mouse lock. |
232 virtual void LostMouseLock(); | 240 virtual void LostMouseLock(); |
233 | 241 |
234 // Noifies the RenderWidget of the current mouse cursor visibility state. | 242 // Noifies the RenderWidget of the current mouse cursor visibility state. |
235 void SendCursorVisibilityState(bool is_visible); | 243 void SendCursorVisibilityState(bool is_visible); |
236 | 244 |
237 // Notifies the RenderWidgetHost that the View was destroyed. | 245 // Notifies the RenderWidgetHost that the View was destroyed. |
238 void ViewDestroyed(); | 246 void ViewDestroyed(); |
239 | 247 |
240 #if defined(OS_MACOSX) | 248 #if defined(OS_MACOSX) |
(...skipping 593 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
834 | 842 |
835 int next_browser_snapshot_id_; | 843 int next_browser_snapshot_id_; |
836 typedef std::map<int, | 844 typedef std::map<int, |
837 base::Callback<void(const unsigned char*, size_t)> > PendingSnapshotMap; | 845 base::Callback<void(const unsigned char*, size_t)> > PendingSnapshotMap; |
838 PendingSnapshotMap pending_browser_snapshots_; | 846 PendingSnapshotMap pending_browser_snapshots_; |
839 | 847 |
840 // Indicates whether a RenderFramehost has ownership, in which case this | 848 // Indicates whether a RenderFramehost has ownership, in which case this |
841 // object does not self destroy. | 849 // object does not self destroy. |
842 bool owned_by_render_frame_host_; | 850 bool owned_by_render_frame_host_; |
843 | 851 |
852 // Indicates whether this frame is focused. This is trying to match what the | |
Charlie Reis
2015/02/04 17:32:43
nit: thinks it is focused.
mlamouri (slow - plz ping)
2015/02/04 17:44:12
Done.
| |
853 // renderer process knows. It is different from RenderWidgetHostView::HasFocus | |
854 // in that regard. | |
Charlie Reis
2015/02/04 17:32:43
nit: in that regard -> in that the focus request m
mlamouri (slow - plz ping)
2015/02/04 17:44:12
Done.
| |
855 bool is_focused_; | |
856 | |
844 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_; | 857 base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_; |
845 | 858 |
846 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); | 859 DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); |
847 }; | 860 }; |
848 | 861 |
849 } // namespace content | 862 } // namespace content |
850 | 863 |
851 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ | 864 #endif // CONTENT_BROWSER_RENDERER_HOST_RENDER_WIDGET_HOST_IMPL_H_ |
OLD | NEW |