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

Side by Side Diff: ios/web/web_state/web_state_impl.mm

Issue 2879413002: Pass NavigationContext to WebStateImpl::OnNavigationStarted. (Closed)
Patch Set: Fixed tests Created 3 years, 7 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 | « ios/web/web_state/web_state_impl.h ('k') | ios/web/web_state/web_state_impl_unittest.mm » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #import "ios/web/web_state/web_state_impl.h" 5 #import "ios/web/web_state/web_state_impl.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 652 matching lines...) Expand 10 before | Expand all | Expand 10 after
663 } 663 }
664 664
665 id<CRWWebViewProxy> WebStateImpl::GetWebViewProxy() const { 665 id<CRWWebViewProxy> WebStateImpl::GetWebViewProxy() const {
666 return [web_controller_ webViewProxy]; 666 return [web_controller_ webViewProxy];
667 } 667 }
668 668
669 bool WebStateImpl::HasOpener() const { 669 bool WebStateImpl::HasOpener() const {
670 return created_with_opener_; 670 return created_with_opener_;
671 } 671 }
672 672
673 void WebStateImpl::OnProvisionalNavigationStarted(const GURL& url) { 673 void WebStateImpl::OnNavigationStarted(web::NavigationContext* context) {
674 // TODO(crbug.com/713836): pass context to WebStateObserver callback.
674 for (auto& observer : observers_) 675 for (auto& observer : observers_)
675 observer.ProvisionalNavigationStarted(url); 676 observer.ProvisionalNavigationStarted(context->GetUrl());
676 } 677 }
677 678
678 void WebStateImpl::OnNavigationFinished(web::NavigationContext* context) { 679 void WebStateImpl::OnNavigationFinished(web::NavigationContext* context) {
679 for (auto& observer : observers_) 680 for (auto& observer : observers_)
680 observer.DidFinishNavigation(context); 681 observer.DidFinishNavigation(context);
681 } 682 }
682 683
683 #pragma mark - NavigationManagerDelegate implementation 684 #pragma mark - NavigationManagerDelegate implementation
684 685
685 void WebStateImpl::GoToIndex(int index) { 686 void WebStateImpl::GoToIndex(int index) {
(...skipping 23 matching lines...) Expand all
709 const LoadCommittedDetails& load_details) { 710 const LoadCommittedDetails& load_details) {
710 for (auto& observer : observers_) 711 for (auto& observer : observers_)
711 observer.NavigationItemCommitted(load_details); 712 observer.NavigationItemCommitted(load_details);
712 } 713 }
713 714
714 WebState* WebStateImpl::GetWebState() { 715 WebState* WebStateImpl::GetWebState() {
715 return this; 716 return this;
716 } 717 }
717 718
718 } // namespace web 719 } // namespace web
OLDNEW
« no previous file with comments | « ios/web/web_state/web_state_impl.h ('k') | ios/web/web_state/web_state_impl_unittest.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698