Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(420)

Side by Side Diff: ui/views/controls/webview/webview.h

Issue 108063004: Give up focus if the focused view becomes unfocusable (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Return early if not focused Created 6 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | ui/views/controls/webview/webview.cc » ('j') | ui/views/view.cc » ('J')
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_ 5 #ifndef UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_
6 #define UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_ 6 #define UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "base/memory/scoped_ptr.h" 9 #include "base/memory/scoped_ptr.h"
10 #include "content/public/browser/web_contents_delegate.h" 10 #include "content/public/browser/web_contents_delegate.h"
(...skipping 90 matching lines...) Expand 10 before | Expand all | Expand 10 after
101 // the previously owned WebContents. 101 // the previously owned WebContents.
102 scoped_ptr<content::WebContents> SwapWebContents( 102 scoped_ptr<content::WebContents> SwapWebContents(
103 scoped_ptr<content::WebContents> new_web_contents); 103 scoped_ptr<content::WebContents> new_web_contents);
104 104
105 // Overridden from View: 105 // Overridden from View:
106 virtual void OnBoundsChanged(const gfx::Rect& previous_bounds) OVERRIDE; 106 virtual void OnBoundsChanged(const gfx::Rect& previous_bounds) OVERRIDE;
107 virtual void ViewHierarchyChanged( 107 virtual void ViewHierarchyChanged(
108 const ViewHierarchyChangedDetails& details) OVERRIDE; 108 const ViewHierarchyChangedDetails& details) OVERRIDE;
109 virtual bool SkipDefaultKeyEventProcessing( 109 virtual bool SkipDefaultKeyEventProcessing(
110 const ui::KeyEvent& event) OVERRIDE; 110 const ui::KeyEvent& event) OVERRIDE;
111 virtual bool IsFocusable() const OVERRIDE;
112 virtual void OnFocus() OVERRIDE; 111 virtual void OnFocus() OVERRIDE;
113 virtual void AboutToRequestFocusFromTabTraversal(bool reverse) OVERRIDE; 112 virtual void AboutToRequestFocusFromTabTraversal(bool reverse) OVERRIDE;
114 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE; 113 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE;
115 virtual gfx::NativeViewAccessible GetNativeViewAccessible() OVERRIDE; 114 virtual gfx::NativeViewAccessible GetNativeViewAccessible() OVERRIDE;
116 virtual gfx::Size GetPreferredSize() const OVERRIDE; 115 virtual gfx::Size GetPreferredSize() const OVERRIDE;
117 116
118 // Overridden from content::WebContentsDelegate: 117 // Overridden from content::WebContentsDelegate:
119 virtual void WebContentsFocused(content::WebContents* web_contents) OVERRIDE; 118 virtual void WebContentsFocused(content::WebContents* web_contents) OVERRIDE;
120 virtual bool EmbedsFullscreenWidget() const OVERRIDE; 119 virtual bool EmbedsFullscreenWidget() const OVERRIDE;
121 120
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
160 content::BrowserContext* browser_context_; 159 content::BrowserContext* browser_context_;
161 bool allow_accelerators_; 160 bool allow_accelerators_;
162 gfx::Size preferred_size_; 161 gfx::Size preferred_size_;
163 162
164 DISALLOW_COPY_AND_ASSIGN(WebView); 163 DISALLOW_COPY_AND_ASSIGN(WebView);
165 }; 164 };
166 165
167 } // namespace views 166 } // namespace views
168 167
169 #endif // UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_ 168 #endif // UI_VIEWS_CONTROLS_WEBVIEW_WEBVIEW_H_
OLDNEW
« no previous file with comments | « no previous file | ui/views/controls/webview/webview.cc » ('j') | ui/views/view.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698