summaryrefslogtreecommitdiffstats
path: root/WebCore/bindings/v8/ScriptDebugServer.h
diff options
context:
space:
mode:
authorLeon Clarke <leonclarke@google.com>2010-06-03 14:33:32 +0100
committerLeon Clarke <leonclarke@google.com>2010-06-08 12:24:51 +0100
commit5af96e2c7b73ebc627c6894727826a7576d31758 (patch)
treef9d5e6f6175ccd7e3d14de9b290f08937a0d17ba /WebCore/bindings/v8/ScriptDebugServer.h
parent8cc4fcf4f6adcbc0e0aebfc24fbad9a4cddf2cfb (diff)
downloadexternal_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.zip
external_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.tar.gz
external_webkit-5af96e2c7b73ebc627c6894727826a7576d31758.tar.bz2
Merge webkit.org at r60469 : Initial merge by git.
Change-Id: I66a0047aa2af802f66bb0c7f2a8b02247a596234
Diffstat (limited to 'WebCore/bindings/v8/ScriptDebugServer.h')
-rw-r--r--WebCore/bindings/v8/ScriptDebugServer.h29
1 files changed, 15 insertions, 14 deletions
diff --git a/WebCore/bindings/v8/ScriptDebugServer.h b/WebCore/bindings/v8/ScriptDebugServer.h
index 6ef0afd..7c8c5cc 100644
--- a/WebCore/bindings/v8/ScriptDebugServer.h
+++ b/WebCore/bindings/v8/ScriptDebugServer.h
@@ -36,12 +36,12 @@
#include "JavaScriptCallFrame.h"
#include "PlatformString.h"
#include "ScriptBreakpoint.h"
-#include "ScriptState.h"
#include "StringHash.h"
#include "Timer.h"
#include <v8-debug.h>
#include <wtf/HashMap.h>
#include <wtf/Noncopyable.h>
+#include <wtf/PassOwnPtr.h>
namespace WebCore {
@@ -77,15 +77,18 @@ public:
void recompileAllJSFunctionsSoon() { }
void recompileAllJSFunctions(Timer<ScriptDebugServer>* = 0) { }
- ScriptState* currentCallFrameState();
-
void pageCreated(Page*) { }
// v8-specific methods.
void setDebuggerScriptSource(const String& scriptSource);
- typedef void (*MessageLoopDispatchHandler)(const Vector<WebCore::Page*>&);
- static void setMessageLoopDispatchHandler(MessageLoopDispatchHandler messageLoopDispatchHandler) { s_messageLoopDispatchHandler = messageLoopDispatchHandler; }
+ class ClientMessageLoop {
+ public:
+ virtual ~ClientMessageLoop() { }
+ virtual void run(Page*) = 0;
+ virtual void quitNow() = 0;
+ };
+ void setClientMessageLoop(PassOwnPtr<ClientMessageLoop> clientMessageLoop) { m_clientMessageLoop = clientMessageLoop; }
PassRefPtr<JavaScriptCallFrame> currentCallFrame();
@@ -93,14 +96,13 @@ private:
ScriptDebugServer();
~ScriptDebugServer() { }
- static void onV8DebugMessage(const v8::Debug::Message& message);
- static void onV8DebugHostDispatch();
-
- void handleV8DebugMessage(const v8::Debug::Message& message);
- void handleV8DebugHostDispatch();
+#if ENABLE(V8_SCRIPT_DEBUG_SERVER)
+ static void v8DebugEventCallback(const v8::Debug::EventDetails& eventDetails);
+ void handleV8DebugEvent(const v8::Debug::EventDetails& eventDetails);
+#endif
void dispatchDidParseSource(ScriptDebugListener* listener, v8::Handle<v8::Object> sourceObject);
-
+
void ensureDebuggerScriptCompiled();
void didResume();
@@ -109,11 +111,10 @@ private:
String m_debuggerScriptSource;
PauseOnExceptionsState m_pauseOnExceptionsState;
OwnHandle<v8::Object> m_debuggerScript;
- ScriptState* m_currentCallFrameState;
RefPtr<JavaScriptCallFrame> m_currentCallFrame;
OwnHandle<v8::Object> m_executionState;
-
- static MessageLoopDispatchHandler s_messageLoopDispatchHandler;
+ OwnPtr<ClientMessageLoop> m_clientMessageLoop;
+ Page* m_pausedPage;
};
} // namespace WebCore