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

Side by Side Diff: content/browser/devtools/render_frame_devtools_agent_host.h

Issue 2933243002: [DevTools] Make DevToolsSession own it's DevToolsMessageChunkProcessor (Closed)
Patch Set: more concise 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_ 5 #ifndef CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_
6 #define CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_ 6 #define CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_
7 7
8 #include <map> 8 #include <map>
9 #include <memory> 9 #include <memory>
10 #include <unordered_set> 10 #include <unordered_set>
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 #if defined(OS_ANDROID) 164 #if defined(OS_ANDROID)
165 device::mojom::WakeLockPtr wake_lock_; 165 device::mojom::WakeLockPtr wake_lock_;
166 #endif 166 #endif
167 RenderFrameHostImpl* handlers_frame_host_; 167 RenderFrameHostImpl* handlers_frame_host_;
168 bool current_frame_crashed_; 168 bool current_frame_crashed_;
169 169
170 // PlzNavigate 170 // PlzNavigate
171 171
172 // The active host we are talking to. 172 // The active host we are talking to.
173 RenderFrameHostImpl* frame_host_ = nullptr; 173 RenderFrameHostImpl* frame_host_ = nullptr;
174 std::unordered_set<NavigationHandleImpl*> navigation_handles_;
caseq 2017/06/13 19:52:26 flat_set? ;)
dgozman 2017/06/16 17:58:46 Done.
175 bool render_frame_alive_ = false;
176
177 // These messages were queued after suspending, not sent to the agent,
178 // and will be sent after resuming.
174 struct Message { 179 struct Message {
175 int session_id; 180 int session_id;
181 int call_id;
176 std::string method; 182 std::string method;
177 std::string message; 183 std::string message;
178 }; 184 };
179 // Chunk processor's state cookie always corresponds to a state before 185 std::vector<Message> suspended_messages_;
180 // any of the suspended or waiting for response messages have been handled.
181 DevToolsMessageChunkProcessor chunk_processor_;
182 std::unordered_set<NavigationHandleImpl*> navigation_handles_;
183 bool render_frame_alive_ = false;
184 // These messages were sent before suspending, but their result have not been
185 // received yet, and state cookie has not been updated.
186 std::map<int, Message> waiting_for_response_messages_;
187 // These messages were queued after suspending, not sent to the agent,
188 // and will be sent after resuming.
189 std::map<int, Message> suspended_messages_;
190 186
191 // The FrameTreeNode associated with this agent. 187 // The FrameTreeNode associated with this agent.
192 FrameTreeNode* frame_tree_node_; 188 FrameTreeNode* frame_tree_node_;
193 189
194 DISALLOW_COPY_AND_ASSIGN(RenderFrameDevToolsAgentHost); 190 DISALLOW_COPY_AND_ASSIGN(RenderFrameDevToolsAgentHost);
195 }; 191 };
196 192
197 } // namespace content 193 } // namespace content
198 194
199 #endif // CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_ 195 #endif // CONTENT_BROWSER_DEVTOOLS_RENDER_FRAME_DEVTOOLS_AGENT_HOST_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698