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

Unified Diff: chrome/browser/ui/webui/signin/signin_dice_internals_ui.cc

Issue 2943093002: Add internals page for DICE (Closed)
Patch Set: Fix compile error Created 3 years, 6 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/ui/webui/signin/signin_dice_internals_ui.h ('k') | chrome/common/url_constants.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/signin/signin_dice_internals_ui.cc
diff --git a/chrome/browser/ui/webui/signin/signin_dice_internals_ui.cc b/chrome/browser/ui/webui/signin/signin_dice_internals_ui.cc
new file mode 100644
index 0000000000000000000000000000000000000000..5b936a2f7f4a1d10000ace77723e0fe168e02e6c
--- /dev/null
+++ b/chrome/browser/ui/webui/signin/signin_dice_internals_ui.cc
@@ -0,0 +1,31 @@
+// Copyright 2017 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.
+
+#include "chrome/browser/ui/webui/signin/signin_dice_internals_ui.h"
+
+#include "chrome/browser/profiles/profile.h"
+#include "chrome/browser/ui/webui/signin/signin_dice_internals_handler.h"
+#include "chrome/common/url_constants.h"
+#include "chrome/grit/browser_resources.h"
+#include "components/grit/components_resources.h"
+#include "content/public/browser/web_ui.h"
+#include "content/public/browser/web_ui_data_source.h"
+
+SigninDiceInternalsUI::SigninDiceInternalsUI(content::WebUI* web_ui)
+ : WebUIController(web_ui) {
+ Profile* profile = Profile::FromWebUI(web_ui);
+ DCHECK(!profile->IsOffTheRecord());
+
+ content::WebUIDataSource* source = content::WebUIDataSource::Create(
+ chrome::kChromeUISigninDiceInternalsHost);
+ source->AddResourcePath("signin_dice_internals.js",
+ IDR_SIGNIN_DICE_INTERNALS_JS);
+ source->SetDefaultResource(IDR_SIGNIN_DICE_INTERNALS_HTML);
+ content::WebUIDataSource::Add(profile, source);
+
+ web_ui->AddMessageHandler(
+ base::MakeUnique<SigninDiceInternalsHandler>(profile));
+}
+
+SigninDiceInternalsUI::~SigninDiceInternalsUI() {}
« no previous file with comments | « chrome/browser/ui/webui/signin/signin_dice_internals_ui.h ('k') | chrome/common/url_constants.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698