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

Unified Diff: ash/common/devtools/ash_devtools_dom_agent.cc

Issue 2738133003: Promotes a handful of members from WmShell to Shell (Closed)
Patch Set: merge Created 3 years, 9 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 | « ash/common/devtools/ash_devtools_dom_agent.h ('k') | ash/common/devtools/ash_devtools_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/common/devtools/ash_devtools_dom_agent.cc
diff --git a/ash/common/devtools/ash_devtools_dom_agent.cc b/ash/common/devtools/ash_devtools_dom_agent.cc
index 79aa433944d49c29a9b175d30cc40baccf143619..f72c249729ee601f47d6d0e626e8cdfaa268531c 100644
--- a/ash/common/devtools/ash_devtools_dom_agent.cc
+++ b/ash/common/devtools/ash_devtools_dom_agent.cc
@@ -7,6 +7,7 @@
#include "ash/common/wm_window.h"
#include "ash/public/cpp/shell_window_ids.h"
#include "ash/root_window_controller.h"
+#include "ash/shell.h"
#include "components/ui_devtools/devtools_server.h"
#include "third_party/skia/include/core/SkColor.h"
#include "ui/display/display.h"
@@ -104,9 +105,7 @@ views::Widget* GetWidgetFromWmWindow(WmWindow* window) {
} // namespace
-AshDevToolsDOMAgent::AshDevToolsDOMAgent(ash::WmShell* shell) : shell_(shell) {
- DCHECK(shell_);
-}
+AshDevToolsDOMAgent::AshDevToolsDOMAgent() {}
AshDevToolsDOMAgent::~AshDevToolsDOMAgent() {
RemoveObservers();
@@ -247,8 +246,8 @@ void AshDevToolsDOMAgent::RemoveObserver(
std::unique_ptr<ui::devtools::protocol::DOM::Node>
AshDevToolsDOMAgent::BuildInitialTree() {
std::unique_ptr<Array<DOM::Node>> children = Array<DOM::Node>::create();
- for (ash::WmWindow* window : shell_->GetAllRootWindows())
- children->addItem(BuildTreeForWindow(window));
+ for (aura::Window* window : Shell::GetAllRootWindows())
+ children->addItem(BuildTreeForWindow(WmWindow::Get(window)));
return BuildNode("root", nullptr, std::move(children));
}
@@ -475,7 +474,7 @@ void AshDevToolsDOMAgent::InitializeHighlightingWidget() {
params.ownership = views::Widget::InitParams::WIDGET_OWNS_NATIVE_WIDGET;
params.opacity = views::Widget::InitParams::WindowOpacity::TRANSLUCENT_WINDOW;
params.name = "HighlightingWidget";
- shell_->GetPrimaryRootWindowController()
+ Shell::GetPrimaryRootWindowController()
->ConfigureWidgetInitParamsForContainer(widget_for_highlighting_.get(),
kShellWindowId_OverlayContainer,
&params);
« no previous file with comments | « ash/common/devtools/ash_devtools_dom_agent.h ('k') | ash/common/devtools/ash_devtools_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698