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.
5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_VIEW_HOST_FACTORY_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_VIEW_HOST_FACTORY_H_
8 #include "base/basictypes.h"
14 namespace extensions
{
16 class ExtensionViewHost
;
18 // A utility class to make ExtensionViewHosts for UI views that are backed
20 class ExtensionViewHostFactory
{
22 // Creates a new ExtensionHost with its associated view, grouping it in the
23 // appropriate SiteInstance (and therefore process) based on the URL and
25 static ExtensionViewHost
* CreatePopupHost(const GURL
& url
, Browser
* browser
);
26 static ExtensionViewHost
* CreateInfobarHost(const GURL
& url
,
29 // Some dialogs may not be associated with a particular browser window and
30 // hence only require a |profile|.
31 static ExtensionViewHost
* CreateDialogHost(const GURL
& url
, Profile
* profile
);
34 DISALLOW_COPY_AND_ASSIGN(ExtensionViewHostFactory
);
37 } // namespace extensions
39 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_VIEW_HOST_FACTORY_H_