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

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

Issue 600043004: Add render_frame_host to WebContentsObserver::DidNavigateAnyFrame(). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 6 years, 2 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
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/debug/trace_event.h" 10 #include "base/debug/trace_event.h"
(...skipping 2629 matching lines...) Expand 10 before | Expand all | Expand 10 after
2640 // Now that something has committed, we don't need to track whether the 2640 // Now that something has committed, we don't need to track whether the
2641 // initial page has been accessed. 2641 // initial page has been accessed.
2642 has_accessed_initial_document_ = false; 2642 has_accessed_initial_document_ = false;
2643 2643
2644 // If we navigate off the page, close all JavaScript dialogs. 2644 // If we navigate off the page, close all JavaScript dialogs.
2645 if (dialog_manager_ && !details.is_in_page) 2645 if (dialog_manager_ && !details.is_in_page)
2646 dialog_manager_->CancelActiveAndPendingDialogs(this); 2646 dialog_manager_->CancelActiveAndPendingDialogs(this);
2647 2647
2648 // Notify observers about navigation. 2648 // Notify observers about navigation.
2649 FOR_EACH_OBSERVER(WebContentsObserver, observers_, 2649 FOR_EACH_OBSERVER(WebContentsObserver, observers_,
2650 DidNavigateAnyFrame(details, params)); 2650 DidNavigateAnyFrame(render_frame_host, details, params));
2651 } 2651 }
2652 2652
2653 void WebContentsImpl::SetMainFrameMimeType(const std::string& mime_type) { 2653 void WebContentsImpl::SetMainFrameMimeType(const std::string& mime_type) {
2654 contents_mime_type_ = mime_type; 2654 contents_mime_type_ = mime_type;
2655 } 2655 }
2656 2656
2657 bool WebContentsImpl::CanOverscrollContent() const { 2657 bool WebContentsImpl::CanOverscrollContent() const {
2658 // Disable overscroll when touch emulation is on. See crbug.com/369938. 2658 // Disable overscroll when touch emulation is on. See crbug.com/369938.
2659 if (force_disable_overscroll_content_) 2659 if (force_disable_overscroll_content_)
2660 return false; 2660 return false;
(...skipping 1712 matching lines...) Expand 10 before | Expand all | Expand 10 after
4373 node->render_manager()->ResumeResponseDeferredAtStart(); 4373 node->render_manager()->ResumeResponseDeferredAtStart();
4374 } 4374 }
4375 4375
4376 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) { 4376 void WebContentsImpl::SetForceDisableOverscrollContent(bool force_disable) {
4377 force_disable_overscroll_content_ = force_disable; 4377 force_disable_overscroll_content_ = force_disable;
4378 if (view_) 4378 if (view_)
4379 view_->SetOverscrollControllerEnabled(CanOverscrollContent()); 4379 view_->SetOverscrollControllerEnabled(CanOverscrollContent());
4380 } 4380 }
4381 4381
4382 } // namespace content 4382 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/android/web_contents_observer_android.cc ('k') | content/public/browser/web_contents_observer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698