1 // Copyright 2015 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.
5 #ifndef IOS_WEB_INTERSTITIALS_WEB_INTERSTITIAL_FACADE_DELEGATE_H_
6 #define IOS_WEB_INTERSTITIALS_WEB_INTERSTITIAL_FACADE_DELEGATE_H_
9 class InterstitialPage
;
14 class WebInterstitialImpl
;
16 // Interface used by WebInterstitials to drive their InterstitialPage facades.
17 class WebInterstitialFacadeDelegate
{
19 WebInterstitialFacadeDelegate() {}
20 virtual ~WebInterstitialFacadeDelegate() {}
22 // Sets the WebStateImpl that backs the WebContents facade.
23 virtual void SetWebInterstitial(WebInterstitialImpl
* web_interstitial
) = 0;
24 // Returns the facade object being driven by this delegate.
25 virtual content::InterstitialPage
* GetInterstitialPageFacade() = 0;
27 // Called when the WebInterstitial is being destroyed. Since WebInterstitials
28 // manage their own deletion, this gives the delegate a chance to deallocate
29 // the InterstitialPage facade.
30 virtual void WebInterstitialDestroyed() = 0;
35 #endif // IOS_WEB_INTERSTITIALS_WEB_INTERSTITIAL_FACADE_DELEGATE_H_