Chromium Code Reviews| 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 #include "content/browser/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 1967 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1978 int id = StartDownload(host, url, image_size); | 1978 int id = StartDownload(host, url, image_size); |
| 1979 favicon_download_map_[id] = callback; | 1979 favicon_download_map_[id] = callback; |
| 1980 return id; | 1980 return id; |
| 1981 } | 1981 } |
| 1982 | 1982 |
| 1983 bool WebContentsImpl::FocusLocationBarByDefault() { | 1983 bool WebContentsImpl::FocusLocationBarByDefault() { |
| 1984 WebUI* web_ui = GetWebUIForCurrentState(); | 1984 WebUI* web_ui = GetWebUIForCurrentState(); |
| 1985 if (web_ui) | 1985 if (web_ui) |
| 1986 return web_ui->ShouldFocusLocationBarByDefault(); | 1986 return web_ui->ShouldFocusLocationBarByDefault(); |
| 1987 NavigationEntry* entry = controller_.GetActiveEntry(); | 1987 NavigationEntry* entry = controller_.GetActiveEntry(); |
| 1988 return (entry && entry->GetURL() == GURL(chrome::kAboutBlankURL)); | 1988 return (entry && |
| 1989 (entry->GetVirtualURL() == GURL(chrome::kAboutBlankURL) || | |
| 1990 entry->GetVirtualURL() == GURL(chrome::kChromeUINewTabURL))); | |
|
jam
2013/01/29 17:51:55
i dont understand why this change is even needed?
samarth
2013/01/31 16:24:57
It's because with Instant Extended, the new tab pa
jam
2013/02/01 17:44:34
i see. then you'll need to find another way of doi
Charlie Reis
2013/02/01 19:58:57
Perhaps FocusLocationBarByDefault could call out t
samarth
2013/02/04 20:43:32
OK, I backed out all the content/ changes for this
| |
| 1989 } | 1991 } |
| 1990 | 1992 |
| 1991 void WebContentsImpl::SetFocusToLocationBar(bool select_all) { | 1993 void WebContentsImpl::SetFocusToLocationBar(bool select_all) { |
| 1992 if (delegate_) | 1994 if (delegate_) |
| 1993 delegate_->SetFocusToLocationBar(select_all); | 1995 delegate_->SetFocusToLocationBar(select_all); |
| 1994 } | 1996 } |
| 1995 | 1997 |
| 1996 void WebContentsImpl::OnRegisterIntentService( | 1998 void WebContentsImpl::OnRegisterIntentService( |
| 1997 const webkit_glue::WebIntentServiceData& data, | 1999 const webkit_glue::WebIntentServiceData& data, |
| 1998 bool user_gesture) { | 2000 bool user_gesture) { |
| (...skipping 1448 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3447 | 3449 |
| 3448 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { | 3450 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() { |
| 3449 return browser_plugin_guest_.get(); | 3451 return browser_plugin_guest_.get(); |
| 3450 } | 3452 } |
| 3451 | 3453 |
| 3452 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { | 3454 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() { |
| 3453 return browser_plugin_embedder_.get(); | 3455 return browser_plugin_embedder_.get(); |
| 3454 } | 3456 } |
| 3455 | 3457 |
| 3456 } // namespace content | 3458 } // namespace content |
| OLD | NEW |