Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(220)

Side by Side Diff: content/browser/webui/empty_web_ui_factory.h

Issue 7464009: Removal of Profile from content part 1. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: browser_context Created 9 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #ifndef CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_ 5 #ifndef CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_
6 #define CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_ 6 #define CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_
7 7
8 #include "base/memory/singleton.h" 8 #include "base/memory/singleton.h"
9 #include "content/browser/webui/web_ui_factory.h" 9 #include "content/browser/webui/web_ui_factory.h"
10 10
11 namespace content { 11 namespace content {
12 12
13 // A stubbed out version of WebUIFactory. 13 // A stubbed out version of WebUIFactory.
14 class EmptyWebUIFactory : public content::WebUIFactory { 14 class EmptyWebUIFactory : public content::WebUIFactory {
15 public: 15 public:
16 // Returns the singleton instance. 16 // Returns the singleton instance.
17 static EmptyWebUIFactory* GetInstance(); 17 static EmptyWebUIFactory* GetInstance();
18 18
19 virtual WebUI* CreateWebUIForURL(TabContents* source, 19 virtual WebUI* CreateWebUIForURL(TabContents* source,
20 const GURL& url) const; 20 const GURL& url) const OVERRIDE;
21 virtual WebUI::TypeID GetWebUIType(Profile* profile, 21 virtual WebUI::TypeID GetWebUIType(content::BrowserContext* context,
jam 2011/07/22 16:58:38 nit: browser_context
22 const GURL& url) const; 22 const GURL& url) const OVERRIDE;
23 virtual bool UseWebUIForURL(Profile* profile, const GURL& url) const; 23 virtual bool UseWebUIForURL(content::BrowserContext* context,
24 virtual bool HasWebUIScheme(const GURL& url) const; 24 const GURL& url) const OVERRIDE;
25 virtual bool IsURLAcceptableForWebUI(Profile* profile, 25 virtual bool HasWebUIScheme(const GURL& url) const OVERRIDE;
26 const GURL& url) const; 26 virtual bool IsURLAcceptableForWebUI(content::BrowserContext* context,
27 const GURL& url) const OVERRIDE;
27 28
28 protected: 29 protected:
29 EmptyWebUIFactory(); 30 EmptyWebUIFactory();
30 virtual ~EmptyWebUIFactory(); 31 virtual ~EmptyWebUIFactory();
31 32
32 private: 33 private:
33 friend struct DefaultSingletonTraits<EmptyWebUIFactory>; 34 friend struct DefaultSingletonTraits<EmptyWebUIFactory>;
34 }; 35 };
35 36
36 } // namespace content 37 } // namespace content
37 38
38 #endif // CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_ 39 #endif // CONTENT_BROWSER_WEBUI_EMPTY_WEB_UI_FACTORY_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698