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

Side by Side Diff: content/browser/tab_contents/tab_contents.cc

Issue 9834067: Get more data to diagnose a crash. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Initial CL Created 8 years, 9 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 | no next file » | no next file with comments »
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 #include "content/browser/tab_contents/tab_contents.h" 5 #include "content/browser/tab_contents/tab_contents.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 1045 matching lines...) Expand 10 before | Expand all | Expand 10 after
1056 // Double check that here. 1056 // Double check that here.
1057 int enabled_bindings = dest_render_view_host->GetEnabledBindings(); 1057 int enabled_bindings = dest_render_view_host->GetEnabledBindings();
1058 WebUIControllerFactory* factory = 1058 WebUIControllerFactory* factory =
1059 content::GetContentClient()->browser()->GetWebUIControllerFactory(); 1059 content::GetContentClient()->browser()->GetWebUIControllerFactory();
1060 bool is_allowed_in_web_ui_renderer = 1060 bool is_allowed_in_web_ui_renderer =
1061 factory && 1061 factory &&
1062 factory->IsURLAcceptableForWebUI(GetBrowserContext(), entry.GetURL()); 1062 factory->IsURLAcceptableForWebUI(GetBrowserContext(), entry.GetURL());
1063 #if defined(OS_CHROMEOS) 1063 #if defined(OS_CHROMEOS)
1064 is_allowed_in_web_ui_renderer |= entry.GetURL().SchemeIs(chrome::kDataScheme); 1064 is_allowed_in_web_ui_renderer |= entry.GetURL().SchemeIs(chrome::kDataScheme);
1065 #endif 1065 #endif
1066 CHECK(!(enabled_bindings & content::BINDINGS_POLICY_WEB_UI) || 1066 if ((enabled_bindings & content::BINDINGS_POLICY_WEB_UI) &&
1067 is_allowed_in_web_ui_renderer); 1067 !is_allowed_in_web_ui_renderer) {
1068 // Log the URL to help us diagnose this.
jam 2012/03/23 22:12:38 nit: please add the bug number here so we can trac
Charlie Reis 2012/03/23 22:23:13 Done.
1069 content::GetContentClient()->SetActiveURL(entry.GetURL());
1070 CHECK(0);
1071 }
1068 1072
1069 // Tell DevTools agent that it is attached prior to the navigation. 1073 // Tell DevTools agent that it is attached prior to the navigation.
1070 DevToolsManagerImpl::GetInstance()->OnNavigatingToPendingEntry( 1074 DevToolsManagerImpl::GetInstance()->OnNavigatingToPendingEntry(
1071 GetRenderViewHost(), 1075 GetRenderViewHost(),
1072 dest_render_view_host, 1076 dest_render_view_host,
1073 entry.GetURL()); 1077 entry.GetURL());
1074 1078
1075 // Used for page load time metrics. 1079 // Used for page load time metrics.
1076 current_load_start_ = base::TimeTicks::Now(); 1080 current_load_start_ = base::TimeTicks::Now();
1077 1081
(...skipping 1511 matching lines...) Expand 10 before | Expand all | Expand 10 after
2589 void TabContents::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) { 2593 void TabContents::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) {
2590 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh); 2594 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh);
2591 // Can be NULL during tests. 2595 // Can be NULL during tests.
2592 if (rwh_view) 2596 if (rwh_view)
2593 rwh_view->SetSize(GetView()->GetContainerSize()); 2597 rwh_view->SetSize(GetView()->GetContainerSize());
2594 } 2598 }
2595 2599
2596 RenderViewHostImpl* TabContents::GetRenderViewHostImpl() { 2600 RenderViewHostImpl* TabContents::GetRenderViewHostImpl() {
2597 return static_cast<RenderViewHostImpl*>(GetRenderViewHost()); 2601 return static_cast<RenderViewHostImpl*>(GetRenderViewHost());
2598 } 2602 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698