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

Unified Diff: include/v8-debug.h

Issue 281733002: Rename debug API methods. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/v8-debug.h
diff --git a/include/v8-debug.h b/include/v8-debug.h
index 48b96573a10b99aea0af0c4a78ef3f7381611d23..980d4b944e3e613a4d6978556f448b7e4dbb9af3 100644
--- a/include/v8-debug.h
+++ b/include/v8-debug.h
@@ -137,7 +137,10 @@ class V8_EXPORT Debug {
* A EventCallback2 does not take possession of the event data,
* and must not rely on the data persisting after the handler returns.
*/
- typedef void (*EventCallback2)(const EventDetails& event_details);
+ typedef void (*EventCallback)(const EventDetails& event_details);
+
+ // TODO(yangguo) Deprecate this.
+ typedef EventCallback EventCallback2;
/**
* Debug message callback function.
@@ -147,15 +150,24 @@ class V8_EXPORT Debug {
* A MessageHandler2 does not take possession of the message data,
* and must not rely on the data persisting after the handler returns.
*/
- typedef void (*MessageHandler2)(const Message& message);
+ typedef void (*MessageHandler)(const Message& message);
+
+ // TODO(yangguo) Deprecate this.
+ typedef MessageHandler MessageHandler2;
/**
* Callback function for the host to ensure debug messages are processed.
*/
typedef void (*DebugMessageDispatchHandler)();
+ static bool SetDebugEventListener(EventCallback that,
+ Handle<Value> data = Handle<Value>());
+
+ // TODO(yangguo) Deprecate this.
static bool SetDebugEventListener2(EventCallback2 that,
- Handle<Value> data = Handle<Value>());
+ Handle<Value> data = Handle<Value>()) {
+ return SetDebugEventListener(that, data);
+ }
// Schedule a debugger break to happen when JavaScript code is run
// in the given isolate.
@@ -178,7 +190,12 @@ class V8_EXPORT Debug {
}
// Message based interface. The message protocol is JSON.
- static void SetMessageHandler2(MessageHandler2 handler);
+ static void SetMessageHandler(MessageHandler handler);
+
+ // TODO(yangguo) Deprecate this.
+ static void SetMessageHandler2(MessageHandler2 handler) {
+ SetMessageHandler(handler);
+ }
static void SendCommand(Isolate* isolate,
const uint16_t* command, int length,
« no previous file with comments | « no previous file | src/api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698