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 3360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3371 DCHECK([tab navigationManager]); | 3371 DCHECK([tab navigationManager]); |
3372 CRWSessionController* sc = [tab navigationManager]->GetSessionController(); | 3372 CRWSessionController* sc = [tab navigationManager]->GetSessionController(); |
3373 [_toolbarController showTabHistoryPopupInView:[self view] | 3373 [_toolbarController showTabHistoryPopupInView:[self view] |
3374 withSessionEntries:[sc forwardEntries] | 3374 withSessionEntries:[sc forwardEntries] |
3375 forBackHistory:NO]; | 3375 forBackHistory:NO]; |
3376 } | 3376 } |
3377 | 3377 |
3378 - (void)navigateToSelectedEntry:(id)sender { | 3378 - (void)navigateToSelectedEntry:(id)sender { |
3379 DCHECK([sender isKindOfClass:[TabHistoryCell class]]); | 3379 DCHECK([sender isKindOfClass:[TabHistoryCell class]]); |
3380 TabHistoryCell* selectedCell = (TabHistoryCell*)sender; | 3380 TabHistoryCell* selectedCell = (TabHistoryCell*)sender; |
3381 [[_model currentTab] goToEntry:selectedCell.entry]; | 3381 [[_model currentTab] goToItem:selectedCell.entry.navigationItem]; |
3382 [_toolbarController dismissTabHistoryPopup]; | 3382 [_toolbarController dismissTabHistoryPopup]; |
3383 } | 3383 } |
3384 | 3384 |
3385 - (void)print { | 3385 - (void)print { |
3386 Tab* currentTab = [_model currentTab]; | 3386 Tab* currentTab = [_model currentTab]; |
3387 // The UI should prevent users from printing non-printable pages. However, a | 3387 // The UI should prevent users from printing non-printable pages. However, a |
3388 // redirection to an un-printable page can happen before it is reflected in | 3388 // redirection to an un-printable page can happen before it is reflected in |
3389 // the UI. | 3389 // the UI. |
3390 if (![currentTab viewForPrinting]) { | 3390 if (![currentTab viewForPrinting]) { |
3391 [self showSnackbar:l10n_util::GetNSString(IDS_IOS_CANNOT_PRINT_PAGE_ERROR)]; | 3391 [self showSnackbar:l10n_util::GetNSString(IDS_IOS_CANNOT_PRINT_PAGE_ERROR)]; |
(...skipping 1605 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4997 | 4997 |
4998 - (UIView*)voiceSearchButton { | 4998 - (UIView*)voiceSearchButton { |
4999 return _voiceSearchButton; | 4999 return _voiceSearchButton; |
5000 } | 5000 } |
5001 | 5001 |
5002 - (id<LogoAnimationControllerOwner>)logoAnimationControllerOwner { | 5002 - (id<LogoAnimationControllerOwner>)logoAnimationControllerOwner { |
5003 return [self currentLogoAnimationControllerOwner]; | 5003 return [self currentLogoAnimationControllerOwner]; |
5004 } | 5004 } |
5005 | 5005 |
5006 @end | 5006 @end |
OLD | NEW |