eddae27077
* fix: add theme data source for devtools. Co-authored-by: Bill Shen <shenyb32768@gmail.com> * chore: add ut. Co-authored-by: bill.shen <shenyb32768@gmail.com> * chore: remove recording histograms Co-authored-by: Bill Shen <shenyb32768@gmail.com> * fix: add theme data source for devtools. Co-authored-by: Bill Shen <shenyb32768@gmail.com> * chore: separate files Co-authored-by: Bill Shen <shenyb32768@gmail.com> * chore: separate files Co-authored-by: Bill Shen <shenyb32768@gmail.com> * chore: remove pragma once Co-authored-by: Bill Shen <shenyb32768@gmail.com> * chore: fix lint issue. Co-authored-by: bill.shen <shenyb32768@gmail.com> --------- Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com> Co-authored-by: Bill Shen <shenyb32768@gmail.com>
25 lines
885 B
C++
25 lines
885 B
C++
// Copyright (c) 2012 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-CHROMIUM file.
|
|
|
|
#include "shell/browser/ui/devtools_ui.h"
|
|
|
|
#include <memory>
|
|
|
|
#include "content/public/browser/web_ui.h"
|
|
#include "shell/browser/ui/devtools_ui_bundle_data_source.h"
|
|
#include "shell/browser/ui/devtools_ui_theme_data_source.h"
|
|
|
|
namespace electron {
|
|
|
|
DevToolsUI::DevToolsUI(content::BrowserContext* browser_context,
|
|
content::WebUI* web_ui)
|
|
: WebUIController(web_ui) {
|
|
web_ui->SetBindings(content::BindingsPolicySet());
|
|
content::URLDataSource::Add(browser_context,
|
|
std::make_unique<BundledDataSource>());
|
|
content::URLDataSource::Add(browser_context,
|
|
std::make_unique<ThemeDataSource>());
|
|
}
|
|
|
|
} // namespace electron
|