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/app/main_controller.h" | 5 #import "ios/chrome/app/main_controller.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #import <CoreSpotlight/CoreSpotlight.h> | 10 #import <CoreSpotlight/CoreSpotlight.h> |
(...skipping 1538 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1549 if ([command fromChrome]) { | 1549 if ([command fromChrome]) { |
1550 [self dismissModalsAndOpenSelectedTabInMode:ApplicationMode::NORMAL | 1550 [self dismissModalsAndOpenSelectedTabInMode:ApplicationMode::NORMAL |
1551 withURL:[command url] | 1551 withURL:[command url] |
1552 transition:ui::PAGE_TRANSITION_TYPED | 1552 transition:ui::PAGE_TRANSITION_TYPED |
1553 completion:nil]; | 1553 completion:nil]; |
1554 } else { | 1554 } else { |
1555 [self dismissModalDialogsWithCompletion:^{ | 1555 [self dismissModalDialogsWithCompletion:^{ |
1556 self.currentBVC = [command inIncognito] ? self.otrBVC : self.mainBVC; | 1556 self.currentBVC = [command inIncognito] ? self.otrBVC : self.mainBVC; |
1557 [self.currentBVC webPageOrderedOpen:[command url] | 1557 [self.currentBVC webPageOrderedOpen:[command url] |
1558 referrer:[command referrer] | 1558 referrer:[command referrer] |
1559 windowName:[command windowName] | |
1560 inBackground:[command inBackground] | 1559 inBackground:[command inBackground] |
1561 appendTo:[command appendTo]]; | 1560 appendTo:[command appendTo]]; |
1562 }]; | 1561 }]; |
1563 } | 1562 } |
1564 } | 1563 } |
1565 | 1564 |
1566 - (void)openUrlFromSettings:(OpenUrlCommand*)command { | 1565 - (void)openUrlFromSettings:(OpenUrlCommand*)command { |
1567 DCHECK([command fromChrome]); | 1566 DCHECK([command fromChrome]); |
1568 ProceduralBlock completion = ^{ | 1567 ProceduralBlock completion = ^{ |
1569 [self dismissModalsAndOpenSelectedTabInMode:ApplicationMode::NORMAL | 1568 [self dismissModalsAndOpenSelectedTabInMode:ApplicationMode::NORMAL |
(...skipping 1042 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2612 }; | 2611 }; |
2613 | 2612 |
2614 callbackCounter->IncrementCount(); | 2613 callbackCounter->IncrementCount(); |
2615 [self removeBrowsingDataFromBrowserState:_mainBrowserState | 2614 [self removeBrowsingDataFromBrowserState:_mainBrowserState |
2616 mask:removeAllMask | 2615 mask:removeAllMask |
2617 timePeriod:browsing_data::ALL_TIME | 2616 timePeriod:browsing_data::ALL_TIME |
2618 completionHandler:decrementCallbackCounterCount]; | 2617 completionHandler:decrementCallbackCounterCount]; |
2619 } | 2618 } |
2620 | 2619 |
2621 @end | 2620 @end |
OLD | NEW |