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

Side by Side Diff: ios/chrome/browser/tabs/tab.mm

Issue 2703333006: Move the notion of current Tab from TabModel to WebStateList. (Closed)
Patch Set: Rebase. Created 3 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
« no previous file with comments | « ios/chrome/browser/tabs/tab.h ('k') | ios/chrome/browser/tabs/tab_model.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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 #import "ios/chrome/browser/tabs/tab.h" 5 #import "ios/chrome/browser/tabs/tab.h"
6 6
7 #import <CoreLocation/CoreLocation.h> 7 #import <CoreLocation/CoreLocation.h>
8 #import <UIKit/UIKit.h> 8 #import <UIKit/UIKit.h>
9 9
10 #include <utility> 10 #include <utility>
(...skipping 724 matching lines...) Expand 10 before | Expand all | Expand 10 after
735 } 735 }
736 736
737 - (CRWWebController*)webController { 737 - (CRWWebController*)webController {
738 return webStateImpl_ ? webStateImpl_->GetWebController() : nil; 738 return webStateImpl_ ? webStateImpl_->GetWebController() : nil;
739 } 739 }
740 740
741 - (id<TabDialogDelegate>)dialogDelegate { 741 - (id<TabDialogDelegate>)dialogDelegate {
742 return dialogDelegate_; 742 return dialogDelegate_;
743 } 743 }
744 744
745 - (BOOL)loadFinished {
746 return [self.webController loadPhase] == web::PAGE_LOADED;
747 }
748
745 - (void)setDialogDelegate:(id<TabDialogDelegate>)dialogDelegate { 749 - (void)setDialogDelegate:(id<TabDialogDelegate>)dialogDelegate {
746 dialogDelegate_.reset(dialogDelegate); 750 dialogDelegate_.reset(dialogDelegate);
747 } 751 }
748 752
749 - (void)setIsVoiceSearchResultsTab:(BOOL)isVoiceSearchResultsTab { 753 - (void)setIsVoiceSearchResultsTab:(BOOL)isVoiceSearchResultsTab {
750 // There is intentionally no equality check in this setter, as we want the 754 // There is intentionally no equality check in this setter, as we want the
751 // notificaiton to be sent regardless of whether the value has changed. 755 // notificaiton to be sent regardless of whether the value has changed.
752 isVoiceSearchResultsTab_ = isVoiceSearchResultsTab; 756 isVoiceSearchResultsTab_ = isVoiceSearchResultsTab;
753 [parentTabModel_ notifyTabChanged:self]; 757 [parentTabModel_ notifyTabChanged:self];
754 } 758 }
(...skipping 1492 matching lines...) Expand 10 before | Expand all | Expand 10 after
2247 2251
2248 - (TabModel*)parentTabModel { 2252 - (TabModel*)parentTabModel {
2249 return parentTabModel_; 2253 return parentTabModel_;
2250 } 2254 }
2251 2255
2252 - (FormInputAccessoryViewController*)inputAccessoryViewController { 2256 - (FormInputAccessoryViewController*)inputAccessoryViewController {
2253 return inputAccessoryViewController_.get(); 2257 return inputAccessoryViewController_.get();
2254 } 2258 }
2255 2259
2256 @end 2260 @end
OLDNEW
« no previous file with comments | « ios/chrome/browser/tabs/tab.h ('k') | ios/chrome/browser/tabs/tab_model.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698