| 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 "chrome/browser/chromeos/boot_times_loader.h" | 5 #include "chrome/browser/chromeos/boot_times_loader.h" |
| 6 | 6 |
| 7 #include <vector> | 7 #include <vector> |
| 8 | 8 |
| 9 #include "base/bind.h" | 9 #include "base/bind.h" |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 44 if (web_contents) { | 44 if (web_contents) { |
| 45 RenderWidgetHostView* render_widget_host_view = | 45 RenderWidgetHostView* render_widget_host_view = |
| 46 web_contents->GetRenderWidgetHostView(); | 46 web_contents->GetRenderWidgetHostView(); |
| 47 if (render_widget_host_view) | 47 if (render_widget_host_view) |
| 48 return render_widget_host_view->GetRenderWidgetHost(); | 48 return render_widget_host_view->GetRenderWidgetHost(); |
| 49 } | 49 } |
| 50 return NULL; | 50 return NULL; |
| 51 } | 51 } |
| 52 | 52 |
| 53 const std::string GetTabUrl(RenderWidgetHost* rwh) { | 53 const std::string GetTabUrl(RenderWidgetHost* rwh) { |
| 54 RenderWidgetHostView* rwhv = rwh->view(); | 54 RenderWidgetHostView* rwhv = rwh->GetView(); |
| 55 for (BrowserList::const_iterator it = BrowserList::begin(); | 55 for (BrowserList::const_iterator it = BrowserList::begin(); |
| 56 it != BrowserList::end(); | 56 it != BrowserList::end(); |
| 57 ++it) { | 57 ++it) { |
| 58 Browser* browser = *it; | 58 Browser* browser = *it; |
| 59 for (int i = 0, tab_count = browser->tab_count(); i < tab_count; ++i) { | 59 for (int i = 0, tab_count = browser->tab_count(); i < tab_count; ++i) { |
| 60 WebContents* tab = browser->GetWebContentsAt(i); | 60 WebContents* tab = browser->GetWebContentsAt(i); |
| 61 if (tab->GetRenderWidgetHostView() == rwhv) { | 61 if (tab->GetRenderWidgetHostView() == rwhv) { |
| 62 return tab->GetURL().spec(); | 62 return tab->GetURL().spec(); |
| 63 } | 63 } |
| 64 } | 64 } |
| (...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 475 GetRenderWidgetHost(&web_contents->GetController()); | 475 GetRenderWidgetHost(&web_contents->GetController()); |
| 476 render_widget_hosts_loading_.erase(render_widget_host); | 476 render_widget_hosts_loading_.erase(render_widget_host); |
| 477 break; | 477 break; |
| 478 } | 478 } |
| 479 default: | 479 default: |
| 480 break; | 480 break; |
| 481 } | 481 } |
| 482 } | 482 } |
| 483 | 483 |
| 484 } // namespace chromeos | 484 } // namespace chromeos |
| OLD | NEW |