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

Side by Side Diff: ash/devtools/ash_devtools_dom_agent.h

Issue 2902063004: View shows wrong bound when it is highlighted. (Closed)
Patch Set: . Created 3 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_ 5 #ifndef ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
6 #define ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_ 6 #define ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
7 7
8 #include "ash/ash_export.h" 8 #include "ash/ash_export.h"
9 #include "ash/devtools/ui_element_delegate.h" 9 #include "ash/devtools/ui_element_delegate.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 17 matching lines...) Expand all
28 virtual void OnNodeBoundsChanged(int node_id) = 0; 28 virtual void OnNodeBoundsChanged(int node_id) = 0;
29 }; 29 };
30 30
31 class ASH_EXPORT AshDevToolsDOMAgent 31 class ASH_EXPORT AshDevToolsDOMAgent
32 : public NON_EXPORTED_BASE(ui::devtools::UiDevToolsBaseAgent< 32 : public NON_EXPORTED_BASE(ui::devtools::UiDevToolsBaseAgent<
33 ui::devtools::protocol::DOM::Metainfo>), 33 ui::devtools::protocol::DOM::Metainfo>),
34 public UIElementDelegate { 34 public UIElementDelegate {
35 public: 35 public:
36 AshDevToolsDOMAgent(); 36 AshDevToolsDOMAgent();
37 ~AshDevToolsDOMAgent() override; 37 ~AshDevToolsDOMAgent() override;
38 std::unordered_map<int, UIElement*>& node_id_to_ui_element() {
sadrul 2017/05/25 19:07:28 Make it const.
thanhph 2017/05/25 20:16:40 I removed this function.
39 return node_id_to_ui_element_;
40 }
38 41
39 // DOM::Backend: 42 // DOM::Backend:
40 ui::devtools::protocol::Response disable() override; 43 ui::devtools::protocol::Response disable() override;
41 ui::devtools::protocol::Response getDocument( 44 ui::devtools::protocol::Response getDocument(
42 std::unique_ptr<ui::devtools::protocol::DOM::Node>* out_root) override; 45 std::unique_ptr<ui::devtools::protocol::DOM::Node>* out_root) override;
43 ui::devtools::protocol::Response highlightNode( 46 ui::devtools::protocol::Response highlightNode(
44 std::unique_ptr<ui::devtools::protocol::DOM::HighlightConfig> 47 std::unique_ptr<ui::devtools::protocol::DOM::HighlightConfig>
45 highlight_config, 48 highlight_config,
46 ui::devtools::protocol::Maybe<int> node_id) override; 49 ui::devtools::protocol::Maybe<int> node_id) override;
47 ui::devtools::protocol::Response hideHighlight() override; 50 ui::devtools::protocol::Response hideHighlight() override;
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 std::unique_ptr<views::Widget> widget_for_highlighting_; 94 std::unique_ptr<views::Widget> widget_for_highlighting_;
92 base::ObserverList<AshDevToolsDOMAgentObserver> observers_; 95 base::ObserverList<AshDevToolsDOMAgentObserver> observers_;
93 96
94 DISALLOW_COPY_AND_ASSIGN(AshDevToolsDOMAgent); 97 DISALLOW_COPY_AND_ASSIGN(AshDevToolsDOMAgent);
95 }; 98 };
96 99
97 } // namespace devtools 100 } // namespace devtools
98 } // namespace ash 101 } // namespace ash
99 102
100 #endif // ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_ 103 #endif // ASH_DEVTOOLS_ASH_DEVTOOLS_DOM_AGENT_H_
OLDNEW
« no previous file with comments | « no previous file | ash/devtools/ash_devtools_unittest.cc » ('j') | ash/devtools/ash_devtools_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698