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/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 2010 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2021 - (void)webControllerDidSuppressDialog:(id)webController { | 2021 - (void)webControllerDidSuppressDialog:(id)webController { |
2022 DCHECK(isPrerenderTab_); | 2022 DCHECK(isPrerenderTab_); |
2023 [delegate_ discardPrerender]; | 2023 [delegate_ discardPrerender]; |
2024 } | 2024 } |
2025 | 2025 |
2026 - (CRWWebController*)webController:(CRWWebController*)webController | 2026 - (CRWWebController*)webController:(CRWWebController*)webController |
2027 createWebControllerForURL:(const GURL&)URL | 2027 createWebControllerForURL:(const GURL&)URL |
2028 openerURL:(const GURL&)openerURL | 2028 openerURL:(const GURL&)openerURL |
2029 initiatedByUser:(BOOL)initiatedByUser { | 2029 initiatedByUser:(BOOL)initiatedByUser { |
2030 if (!initiatedByUser) { | 2030 if (!initiatedByUser) { |
2031 auto helper = BlockedPopupTabHelper::FromWebState(webController.webState); | 2031 auto* helper = BlockedPopupTabHelper::FromWebState(webController.webState); |
2032 if (helper->ShouldBlockPopup(openerURL)) { | 2032 if (helper->ShouldBlockPopup(openerURL)) { |
2033 [self blockPopupForURL:URL openerURL:openerURL]; | 2033 [self blockPopupForURL:URL openerURL:openerURL]; |
2034 return nil; | 2034 return nil; |
2035 } | 2035 } |
2036 } | 2036 } |
2037 | 2037 |
2038 [self updateSnapshotWithOverlay:YES visibleFrameOnly:YES]; | 2038 [self updateSnapshotWithOverlay:YES visibleFrameOnly:YES]; |
2039 Tab* tab = [parentTabModel_ | 2039 Tab* tab = [parentTabModel_ |
2040 insertBlankTabWithTransition:ui::PAGE_TRANSITION_LINK | 2040 insertBlankTabWithTransition:ui::PAGE_TRANSITION_LINK |
2041 opener:self | 2041 opener:self |
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2247 | 2247 |
2248 - (TabModel*)parentTabModel { | 2248 - (TabModel*)parentTabModel { |
2249 return parentTabModel_; | 2249 return parentTabModel_; |
2250 } | 2250 } |
2251 | 2251 |
2252 - (FormInputAccessoryViewController*)inputAccessoryViewController { | 2252 - (FormInputAccessoryViewController*)inputAccessoryViewController { |
2253 return inputAccessoryViewController_.get(); | 2253 return inputAccessoryViewController_.get(); |
2254 } | 2254 } |
2255 | 2255 |
2256 @end | 2256 @end |
OLD | NEW |