OLD | NEW |
(Empty) | |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef IOS_CHROME_BROWSER_TABS_TAB_LOADING_DELEGATE_H_ |
| 6 #define IOS_CHROME_BROWSER_TABS_TAB_LOADING_DELEGATE_H_ |
| 7 |
| 8 #import <UIKit/UIKit.h> |
| 9 |
| 10 // A protocol implemented by a delegate managing Tab loading. This protocol |
| 11 // is used by a Tab that's being preloaded before being displayed to inform the |
| 12 // entity that's preloading it that it should take some action. In the |
| 13 // QuickBack system, for example, a QuickBackLoadController will start loading |
| 14 // a Tab for a search link, and hold it in this loading state until it's |
| 15 // ready to display. The QuickBackLoadController is then set as this Tab's |
| 16 // TabLoadingDelegate, which allows the Tab to let its owning controller know |
| 17 // if it needs to be cancelled or displayed. |
| 18 @protocol TabLoadingDelegate |
| 19 // Display the preloading tab immediately. |
| 20 - (void)displayPreloadingLinkImmediately; |
| 21 // Cancel preloading tab. |
| 22 - (void)cancelPreloadingTab; |
| 23 // Informs the delegate that the tab aborted load internally (e.g., due to |
| 24 // launching an external URL), so the preloading should be abandoned and the |
| 25 // source tab restored to its pre-load-attempt state. |
| 26 - (void)preloadingTabAborted; |
| 27 |
| 28 @end |
| 29 |
| 30 #endif // IOS_CHROME_BROWSER_TABS_TAB_LOADING_DELEGATE_H_ |
OLD | NEW |