Chromium Code Reviews| OLD | NEW |
|---|---|
| 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/ui/browser_view_controller.h" | 5 #import "ios/chrome/browser/ui/browser_view_controller.h" |
| 6 | 6 |
| 7 #import <AssetsLibrary/AssetsLibrary.h> | 7 #import <AssetsLibrary/AssetsLibrary.h> |
| 8 #import <MobileCoreServices/MobileCoreServices.h> | 8 #import <MobileCoreServices/MobileCoreServices.h> |
| 9 #import <PassKit/PassKit.h> | 9 #import <PassKit/PassKit.h> |
| 10 #import <Photos/Photos.h> | 10 #import <Photos/Photos.h> |
| (...skipping 3275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3286 } | 3286 } |
| 3287 | 3287 |
| 3288 [_toolbarController showToolsMenuPopupWithContext:context]; | 3288 [_toolbarController showToolsMenuPopupWithContext:context]; |
| 3289 ToolsPopupController* toolsPopupController = | 3289 ToolsPopupController* toolsPopupController = |
| 3290 [_toolbarController toolsPopupController]; | 3290 [_toolbarController toolsPopupController]; |
| 3291 if ([_model currentTab]) { | 3291 if ([_model currentTab]) { |
| 3292 BOOL isBookmarked = _toolbarModelIOS->IsCurrentTabBookmarked(); | 3292 BOOL isBookmarked = _toolbarModelIOS->IsCurrentTabBookmarked(); |
| 3293 [toolsPopupController setIsCurrentPageBookmarked:isBookmarked]; | 3293 [toolsPopupController setIsCurrentPageBookmarked:isBookmarked]; |
| 3294 [toolsPopupController setCanShowFindBar:self.canShowFindBar]; | 3294 [toolsPopupController setCanShowFindBar:self.canShowFindBar]; |
| 3295 [toolsPopupController setCanUseReaderMode:self.canUseReaderMode]; | 3295 [toolsPopupController setCanUseReaderMode:self.canUseReaderMode]; |
| 3296 [toolsPopupController | |
| 3297 setCanUseDesktopUserAgent:self.canUseDesktopUserAgent]; | |
| 3298 [toolsPopupController setCanShowShareMenu:self.canShowShareMenu]; | 3296 [toolsPopupController setCanShowShareMenu:self.canShowShareMenu]; |
| 3299 | 3297 |
| 3298 web::UserAgentType userAgentType = [_model currentTab] | |
| 3299 .webState->GetNavigationManager() | |
| 3300 ->GetVisibleItem() | |
|
kkhorimoto
2017/02/27 23:44:24
It's a bug, but I believe there are some instances
liaoyuke
2017/02/28 02:01:00
Done.
| |
| 3301 ->GetUserAgentType(); | |
| 3302 [toolsPopupController setUserAgentType:userAgentType]; | |
|
kkhorimoto
2017/02/27 23:44:24
Let's use dot notation since this is a property no
liaoyuke
2017/02/28 02:01:00
Done.
| |
| 3303 | |
| 3300 if (!IsIPadIdiom()) | 3304 if (!IsIPadIdiom()) |
| 3301 [toolsPopupController setIsTabLoading:_toolbarModelIOS->IsLoading()]; | 3305 [toolsPopupController setIsTabLoading:_toolbarModelIOS->IsLoading()]; |
| 3302 } | 3306 } |
| 3303 } | 3307 } |
| 3304 | 3308 |
| 3305 - (void)showPageInfoPopupForView:(UIView*)sourceView { | 3309 - (void)showPageInfoPopupForView:(UIView*)sourceView { |
| 3306 Tab* tab = [_model currentTab]; | 3310 Tab* tab = [_model currentTab]; |
| 3307 DCHECK([tab navigationManager]); | 3311 DCHECK([tab navigationManager]); |
| 3308 web::NavigationItem* navItem = [tab navigationManager]->GetVisibleItem(); | 3312 web::NavigationItem* navItem = [tab navigationManager]->GetVisibleItem(); |
| 3309 | 3313 |
| (...skipping 1715 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 5025 | 5029 |
| 5026 - (UIView*)voiceSearchButton { | 5030 - (UIView*)voiceSearchButton { |
| 5027 return _voiceSearchButton; | 5031 return _voiceSearchButton; |
| 5028 } | 5032 } |
| 5029 | 5033 |
| 5030 - (id<LogoAnimationControllerOwner>)logoAnimationControllerOwner { | 5034 - (id<LogoAnimationControllerOwner>)logoAnimationControllerOwner { |
| 5031 return [self currentLogoAnimationControllerOwner]; | 5035 return [self currentLogoAnimationControllerOwner]; |
| 5032 } | 5036 } |
| 5033 | 5037 |
| 5034 @end | 5038 @end |
| OLD | NEW |