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

Unified Diff: chrome/browser/dom_ui/dom_ui_factory.cc

Issue 3152055: Implement about:labs (Closed)
Patch Set: chromeos fix Created 10 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/browser_resources.grd ('k') | chrome/browser/dom_ui/labs_ui.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/dom_ui/dom_ui_factory.cc
diff --git a/chrome/browser/dom_ui/dom_ui_factory.cc b/chrome/browser/dom_ui/dom_ui_factory.cc
index 0737acfff401564c5331378b30810963d3d4526e..251f64634bcd1b2c571f574791071cbc74cae6a3 100644
--- a/chrome/browser/dom_ui/dom_ui_factory.cc
+++ b/chrome/browser/dom_ui/dom_ui_factory.cc
@@ -13,6 +13,7 @@
#include "chrome/browser/dom_ui/history_ui.h"
#include "chrome/browser/dom_ui/history2_ui.h"
#include "chrome/browser/dom_ui/html_dialog_ui.h"
+#include "chrome/browser/dom_ui/labs_ui.h"
#include "chrome/browser/dom_ui/net_internals_ui.h"
#include "chrome/browser/dom_ui/new_tab_ui.h"
#include "chrome/browser/dom_ui/options_ui.h"
@@ -22,6 +23,7 @@
#include "chrome/browser/extensions/extension_dom_ui.h"
#include "chrome/browser/extensions/extensions_service.h"
#include "chrome/browser/extensions/extensions_ui.h"
+#include "chrome/browser/labs.h"
#include "chrome/browser/printing/print_dialog_cloud.h"
#include "chrome/browser/profile.h"
#include "chrome/browser/tab_contents/tab_contents.h"
@@ -116,6 +118,8 @@ static DOMUIFactoryFunction GetDOMUIFactoryFunction(const GURL& url) {
return &NewDOMUI<HistoryUI>;
if (url.host() == chrome::kChromeUIHistory2Host)
return &NewDOMUI<HistoryUI2>;
+ if (about_labs::IsEnabled() && url.host() == chrome::kChromeUILabsHost)
+ return &NewDOMUI<LabsUI>;
if (url.host() == chrome::kChromeUINetInternalsHost)
return &NewDOMUI<NetInternalsUI>;
if (url.host() == chrome::kChromeUIPluginsHost)
@@ -229,6 +233,9 @@ RefCountedMemory* DOMUIFactory::GetFaviconResourceBytes(Profile* profile,
if (page_url.host() == chrome::kChromeUIHistory2Host)
return HistoryUI2::GetFaviconResourceBytes();
+ if (about_labs::IsEnabled() && page_url.host() == chrome::kChromeUILabsHost)
+ return LabsUI::GetFaviconResourceBytes();
+
if (page_url.host() == chrome::kChromeUIOptionsHost)
return OptionsUI::GetFaviconResourceBytes();
« no previous file with comments | « chrome/browser/browser_resources.grd ('k') | chrome/browser/dom_ui/labs_ui.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698