| Index: components/ui_devtools/devtools/ui_devtools_dom_agent.h
|
| diff --git a/ash/devtools/ash_devtools_dom_agent.h b/components/ui_devtools/devtools/ui_devtools_dom_agent.h
|
| similarity index 82%
|
| rename from ash/devtools/ash_devtools_dom_agent.h
|
| rename to components/ui_devtools/devtools/ui_devtools_dom_agent.h
|
| index 349fe4129eb2573c35c0f906c9b462ace85b8515..95b1e07c00c2b10f932f0e1e974c92c5b617a16f 100644
|
| --- a/ash/devtools/ash_devtools_dom_agent.h
|
| +++ b/components/ui_devtools/devtools/ui_devtools_dom_agent.h
|
| @@ -2,13 +2,12 @@
|
| // Use of this source code is governed by a BSD-style license that can be
|
| // found in the LICENSE file.
|
|
|
| -#ifndef ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
|
| -#define ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
|
| +#ifndef COMPONENTS_UI_DEVTOOLS_DEVTOOLS_UI_DEVTOOLS_DOM_AGENT_H_
|
| +#define COMPONENTS_UI_DEVTOOLS_DEVTOOLS_UI_DEVTOOLS_DOM_AGENT_H_
|
|
|
| -#include "ash/ash_export.h"
|
| -#include "ash/devtools/ui_element_delegate.h"
|
| #include "base/macros.h"
|
| #include "components/ui_devtools/DOM.h"
|
| +#include "components/ui_devtools/devtools/ui_element_delegate.h"
|
| #include "components/ui_devtools/devtools_base_agent.h"
|
| #include "ui/aura/env_observer.h"
|
| #include "ui/views/view.h"
|
| @@ -18,24 +17,24 @@ namespace aura {
|
| class Window;
|
| }
|
|
|
| -namespace ash {
|
| +namespace ui {
|
| namespace devtools {
|
|
|
| class UIElement;
|
|
|
| -class ASH_EXPORT AshDevToolsDOMAgentObserver {
|
| +class UIDevToolsDOMAgentObserver {
|
| public:
|
| virtual void OnNodeBoundsChanged(int node_id) = 0;
|
| };
|
|
|
| -class ASH_EXPORT AshDevToolsDOMAgent
|
| +class UIDevToolsDOMAgent
|
| : public NON_EXPORTED_BASE(ui::devtools::UiDevToolsBaseAgent<
|
| ui::devtools::protocol::DOM::Metainfo>),
|
| public UIElementDelegate,
|
| public aura::EnvObserver {
|
| public:
|
| - AshDevToolsDOMAgent();
|
| - ~AshDevToolsDOMAgent() override;
|
| + UIDevToolsDOMAgent();
|
| + ~UIDevToolsDOMAgent() override;
|
|
|
| // DOM::Backend:
|
| ui::devtools::protocol::Response disable() override;
|
| @@ -54,8 +53,8 @@ class ASH_EXPORT AshDevToolsDOMAgent
|
| void OnUIElementBoundsChanged(UIElement* ui_element) override;
|
| bool IsHighlightingWindow(aura::Window* window) override;
|
|
|
| - void AddObserver(AshDevToolsDOMAgentObserver* observer);
|
| - void RemoveObserver(AshDevToolsDOMAgentObserver* observer);
|
| + void AddObserver(UIDevToolsDOMAgentObserver* observer);
|
| + void RemoveObserver(UIDevToolsDOMAgentObserver* observer);
|
| UIElement* GetElementFromNodeId(int node_id);
|
| UIElement* window_element_root() const { return window_element_root_; };
|
| const std::vector<aura::Window*>& root_windows() const {
|
| @@ -67,7 +66,7 @@ class ASH_EXPORT AshDevToolsDOMAgent
|
| void OnHostInitialized(aura::WindowTreeHost* host) override;
|
| void OnWindowInitialized(aura::Window* window) override{};
|
|
|
| - // AshDevToolsDOMAgentObserver:
|
| + // UIDevToolsDOMAgentObserver:
|
| void OnNodeBoundsChanged(int node_id);
|
|
|
| std::unique_ptr<ui::devtools::protocol::DOM::Node> BuildInitialTree();
|
| @@ -99,12 +98,12 @@ class ASH_EXPORT AshDevToolsDOMAgent
|
| std::unordered_map<int, UIElement*> node_id_to_ui_element_;
|
| std::unique_ptr<views::Widget> widget_for_highlighting_;
|
| std::vector<aura::Window*> root_windows_;
|
| - base::ObserverList<AshDevToolsDOMAgentObserver> observers_;
|
| + base::ObserverList<UIDevToolsDOMAgentObserver> observers_;
|
|
|
| - DISALLOW_COPY_AND_ASSIGN(AshDevToolsDOMAgent);
|
| + DISALLOW_COPY_AND_ASSIGN(UIDevToolsDOMAgent);
|
| };
|
|
|
| } // namespace devtools
|
| -} // namespace ash
|
| +} // namespace ui
|
|
|
| -#endif // ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
|
| +#endif // COMPONENTS_UI_DEVTOOLS_DEVTOOLS_UI_DEVTOOLS_DOM_AGENT_H_
|
|
|