Commit 900e7368 authored by rohitrao@chromium.org's avatar rohitrao@chromium.org

Minimal SetInitialFocus and RestoreFocus. These aren't final, but this

does resolve the location bar not being focused bug on the mac build.

Patch by Sean Bryant (sean@cyberwang.net).

BUG=9419

Review URL: http://codereview.chromium.org/100140

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@14939 0039d316-1c4b-4281-b951-d872f2087c98
parent 9a136cdf
......@@ -34,3 +34,4 @@ Paul Robinson <paulrobinson85@googlemail.com>
Josué Ratelle <jorat1346@gmail.com>
Edward Crossman <tedoc2000@gmail.com>
Nikita Ofitserov <himikof@gmail.com>
Sean Bryant <sean@cyberwang.net>
......@@ -107,7 +107,9 @@ void TabContentsViewMac::Focus() {
}
void TabContentsViewMac::SetInitialFocus() {
// TODO(port)
// TODO(port): Set focus in the else case correctly.
if (web_contents()->FocusLocationBarByDefault())
web_contents()->delegate()->SetFocusToLocationBar();
}
void TabContentsViewMac::StoreFocus() {
......@@ -116,6 +118,8 @@ void TabContentsViewMac::StoreFocus() {
void TabContentsViewMac::RestoreFocus() {
// TODO(port)
// For now just assume we are viewing the tab for the first time.
SetInitialFocus();
}
void TabContentsViewMac::UpdateDragCursor(bool is_drop_target) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment