Chromium Code Reviews| Index: content/browser/renderer_host/render_widget_host_impl.h |
| diff --git a/content/browser/renderer_host/render_widget_host_impl.h b/content/browser/renderer_host/render_widget_host_impl.h |
| index 80c5e23dc0647583c27ea666732880c052f6f29f..4bb34d4b03a93e96317ca4d5f04e1a6deee35743 100644 |
| --- a/content/browser/renderer_host/render_widget_host_impl.h |
| +++ b/content/browser/renderer_host/render_widget_host_impl.h |
| @@ -228,6 +228,14 @@ class CONTENT_EXPORT RenderWidgetHostImpl |
| virtual void GotFocus(); |
| virtual void LostCapture(); |
| + // 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.
|
| + // 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.
|
| + // 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.
|
| + // RenderWidgetHostView::HasFocus() is checking whether the view is focused so |
| + // 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.
|
| + // but HasFocus() returns false. |
| + bool is_focused() const { return is_focused_; } |
| + |
| // Called to notify the RenderWidget that it has lost the mouse lock. |
| virtual void LostMouseLock(); |
| @@ -841,6 +849,11 @@ class CONTENT_EXPORT RenderWidgetHostImpl |
| // object does not self destroy. |
| bool owned_by_render_frame_host_; |
| + // 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.
|
| + // renderer process knows. It is different from RenderWidgetHostView::HasFocus |
| + // 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.
|
| + bool is_focused_; |
| + |
| base::WeakPtrFactory<RenderWidgetHostImpl> weak_factory_; |
| DISALLOW_COPY_AND_ASSIGN(RenderWidgetHostImpl); |