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

Side by Side Diff: webkit/glue/devtools/debugger_agent_manager.h

Issue 264077: Convert devtools interfaces over to using WebString.... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 11 years, 2 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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 WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_ 5 #ifndef WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_
6 #define WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_ 6 #define WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_
7 7
8 #include <wtf/HashMap.h> 8 #include <wtf/HashMap.h>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 20 matching lines...) Expand all
31 // 31 //
32 // v8 may send a message(e.g. exception event) after which it 32 // v8 may send a message(e.g. exception event) after which it
33 // would expect some actions from the handler. If there is no appropriate 33 // would expect some actions from the handler. If there is no appropriate
34 // debugger agent to handle such messages the manager will perform the action 34 // debugger agent to handle such messages the manager will perform the action
35 // itself, otherwise v8 may hang waiting for the action. 35 // itself, otherwise v8 may hang waiting for the action.
36 class DebuggerAgentManager { 36 class DebuggerAgentManager {
37 public: 37 public:
38 static void DebugAttach(DebuggerAgentImpl* debugger_agent); 38 static void DebugAttach(DebuggerAgentImpl* debugger_agent);
39 static void DebugDetach(DebuggerAgentImpl* debugger_agent); 39 static void DebugDetach(DebuggerAgentImpl* debugger_agent);
40 static void DebugBreak(DebuggerAgentImpl* debugger_agent); 40 static void DebugBreak(DebuggerAgentImpl* debugger_agent);
41 static void DebugCommand(const std::string& command); 41 static void DebugCommand(const WebCore::String& command);
42 42
43 static void ExecuteDebuggerCommand(const std::string& command, 43 static void ExecuteDebuggerCommand(const WebCore::String& command,
44 int caller_id); 44 int caller_id);
45 static void SetMessageLoopDispatchHandler( 45 static void SetMessageLoopDispatchHandler(
46 WebDevToolsAgent::MessageLoopDispatchHandler handler); 46 WebDevToolsAgent::MessageLoopDispatchHandler handler);
47 47
48 // Sets |host_id| as the frame context data. This id is used to filter scripts 48 // Sets |host_id| as the frame context data. This id is used to filter scripts
49 // related to the inspected page. 49 // related to the inspected page.
50 static void SetHostId(WebFrameImpl* webframe, int host_id); 50 static void SetHostId(WebFrameImpl* webframe, int host_id);
51 51
52 static void OnWebViewClosed(WebViewImpl* webview); 52 static void OnWebViewClosed(WebViewImpl* webview);
53 53
(...skipping 15 matching lines...) Expand all
69 private: 69 private:
70 DISALLOW_COPY_AND_ASSIGN(UtilityContextScope); 70 DISALLOW_COPY_AND_ASSIGN(UtilityContextScope);
71 }; 71 };
72 72
73 private: 73 private:
74 DebuggerAgentManager(); 74 DebuggerAgentManager();
75 ~DebuggerAgentManager(); 75 ~DebuggerAgentManager();
76 76
77 static void V8DebugHostDispatchHandler(); 77 static void V8DebugHostDispatchHandler();
78 static void OnV8DebugMessage(const v8::Debug::Message& message); 78 static void OnV8DebugMessage(const v8::Debug::Message& message);
79 static void SendCommandToV8(const string16& cmd, 79 static void SendCommandToV8(const WebCore::String& cmd,
80 v8::Debug::ClientData* data); 80 v8::Debug::ClientData* data);
81 static void SendContinueCommandToV8(); 81 static void SendContinueCommandToV8();
82 82
83 static DebuggerAgentImpl* FindAgentForCurrentV8Context(); 83 static DebuggerAgentImpl* FindAgentForCurrentV8Context();
84 static DebuggerAgentImpl* DebuggerAgentForHostId(int host_id); 84 static DebuggerAgentImpl* DebuggerAgentForHostId(int host_id);
85 85
86 typedef HashMap<int, DebuggerAgentImpl*> AttachedAgentsMap; 86 typedef HashMap<int, DebuggerAgentImpl*> AttachedAgentsMap;
87 static AttachedAgentsMap* attached_agents_map_; 87 static AttachedAgentsMap* attached_agents_map_;
88 88
89 static WebDevToolsAgent::MessageLoopDispatchHandler 89 static WebDevToolsAgent::MessageLoopDispatchHandler
90 message_loop_dispatch_handler_; 90 message_loop_dispatch_handler_;
91 static bool in_host_dispatch_handler_; 91 static bool in_host_dispatch_handler_;
92 typedef HashMap<WebViewImpl*, WebCore::PageGroupLoadDeferrer*> 92 typedef HashMap<WebViewImpl*, WebCore::PageGroupLoadDeferrer*>
93 DeferrersMap; 93 DeferrersMap;
94 static DeferrersMap page_deferrers_; 94 static DeferrersMap page_deferrers_;
95 95
96 static bool in_utility_context_; 96 static bool in_utility_context_;
97 static bool debug_break_delayed_; 97 static bool debug_break_delayed_;
98 98
99 DISALLOW_COPY_AND_ASSIGN(DebuggerAgentManager); 99 DISALLOW_COPY_AND_ASSIGN(DebuggerAgentManager);
100 }; 100 };
101 101
102 #endif // WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_ 102 #endif // WEBKIT_GLUE_DEVTOOLS_DEBUGGER_AGENT_MANAGER_H_
OLDNEW
« no previous file with comments | « webkit/glue/devtools/debugger_agent_impl.cc ('k') | webkit/glue/devtools/debugger_agent_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698