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

Side by Side Diff: content/browser/web_contents/web_contents_impl.cc

Issue 1532873003: PlzNavigate: add initial traces for new TBM benchmarks. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed crash issue for synchronous navigations. Created 4 years, 11 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
« no previous file with comments | « content/browser/loader/resource_dispatcher_host_impl.cc ('k') | 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/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/lazy_instance.h" 10 #include "base/lazy_instance.h"
(...skipping 3560 matching lines...) Expand 10 before | Expand all | Expand 10 after
3571 is_loading_ = is_loading; 3571 is_loading_ = is_loading;
3572 waiting_for_response_ = is_loading; 3572 waiting_for_response_ = is_loading;
3573 is_load_to_different_document_ = to_different_document; 3573 is_load_to_different_document_ = to_different_document;
3574 3574
3575 if (delegate_) 3575 if (delegate_)
3576 delegate_->LoadingStateChanged(this, to_different_document); 3576 delegate_->LoadingStateChanged(this, to_different_document);
3577 NotifyNavigationStateChanged(INVALIDATE_TYPE_LOAD); 3577 NotifyNavigationStateChanged(INVALIDATE_TYPE_LOAD);
3578 3578
3579 std::string url = (details ? details->url.possibly_invalid_spec() : "NULL"); 3579 std::string url = (details ? details->url.possibly_invalid_spec() : "NULL");
3580 if (is_loading) { 3580 if (is_loading) {
3581 TRACE_EVENT_ASYNC_BEGIN1("browser,navigation", "WebContentsImpl Loading", 3581 TRACE_EVENT_ASYNC_BEGIN2("browser,navigation", "WebContentsImpl Loading",
3582 this, "URL", url); 3582 this, "URL", url, "Main FrameTreeNode id",
3583 GetFrameTree()->root()->frame_tree_node_id());
3583 FOR_EACH_OBSERVER(WebContentsObserver, observers_, DidStartLoading()); 3584 FOR_EACH_OBSERVER(WebContentsObserver, observers_, DidStartLoading());
3584 } else { 3585 } else {
3585 TRACE_EVENT_ASYNC_END1("browser,navigation", "WebContentsImpl Loading", 3586 TRACE_EVENT_ASYNC_END1("browser,navigation", "WebContentsImpl Loading",
3586 this, "URL", url); 3587 this, "URL", url);
3587 FOR_EACH_OBSERVER(WebContentsObserver, observers_, DidStopLoading()); 3588 FOR_EACH_OBSERVER(WebContentsObserver, observers_, DidStopLoading());
3588 } 3589 }
3589 3590
3590 // TODO(avi): Remove. http://crbug.com/170921 3591 // TODO(avi): Remove. http://crbug.com/170921
3591 int type = is_loading ? NOTIFICATION_LOAD_START : NOTIFICATION_LOAD_STOP; 3592 int type = is_loading ? NOTIFICATION_LOAD_START : NOTIFICATION_LOAD_STOP;
3592 NotificationDetails det = NotificationService::NoDetails(); 3593 NotificationDetails det = NotificationService::NoDetails();
(...skipping 1122 matching lines...) Expand 10 before | Expand all | Expand 10 after
4715 const WebContentsObserver::MediaPlayerId& id) { 4716 const WebContentsObserver::MediaPlayerId& id) {
4716 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStartedPlaying(id)); 4717 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStartedPlaying(id));
4717 } 4718 }
4718 4719
4719 void WebContentsImpl::MediaStoppedPlaying( 4720 void WebContentsImpl::MediaStoppedPlaying(
4720 const WebContentsObserver::MediaPlayerId& id) { 4721 const WebContentsObserver::MediaPlayerId& id) {
4721 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStoppedPlaying(id)); 4722 FOR_EACH_OBSERVER(WebContentsObserver, observers_, MediaStoppedPlaying(id));
4722 } 4723 }
4723 4724
4724 } // namespace content 4725 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/loader/resource_dispatcher_host_impl.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698