blob: 53b9be533f3e9cad650a8a3f5706a3e8e7766aa7 [file] [log] [blame]
// Copyright 2015 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
namespace extensions {
class DeferredStartRenderHostObserver;
// A browser component that tracks a renderer. It allows for its renderer
// startup to be deferred, to throttle resource usage upon profile startup.
// To be used with ExtensionHostQueue.
// Note that if BackgroundContents and ExtensionHost are unified
// (, this interface will be no longer needed.
class DeferredStartRenderHost {
virtual ~DeferredStartRenderHost() {}
// DeferredStartRenderHost lifetime can be observed.
virtual void AddDeferredStartRenderHostObserver(
DeferredStartRenderHostObserver* observer) = 0;
virtual void RemoveDeferredStartRenderHostObserver(
DeferredStartRenderHostObserver* observer) = 0;
// DO NOT CALL THIS unless you're implementing an ExtensionHostQueue.
// Called by the ExtensionHostQueue to create the RenderView.
virtual void CreateRenderViewNow() = 0;
} // namespace extensions