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

Unified Diff: runtime/include/dart_api.h

Issue 9325022: Decode the Dart message into a Dart_CMessage structure before calling the native port callback (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 11 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 | runtime/vm/dart_api_impl_test.cc » ('j') | runtime/vm/growable_array.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/include/dart_api.h
diff --git a/runtime/include/dart_api.h b/runtime/include/dart_api.h
index 140f0b1c2d661405daddf03ba8f2b4be2846855a..a706bfff0b2276cd2fbaa8395f3c6d6ab3e120df 100755
--- a/runtime/include/dart_api.h
+++ b/runtime/include/dart_api.h
@@ -556,11 +556,16 @@ DART_EXPORT bool Dart_Post(Dart_Port port_id, Dart_Handle object);
*
* This handler is associated with a native port by calling
* Dart_NewNativePort.
+ *
+ * The message received is decoded into the message structure. The
+ * lifetime of the message data is controlled by the caller. All the
+ * data references from the message are allocated by the caller and
+ * will be reclaimed when returning to it.
*/
+struct Dart_CMessage;
siva 2012/02/04 01:55:43 Why not move the section /** Message sending/recei
Søren Gjesse 2012/02/06 16:25:52 Done.
typedef void (*Dart_NativeMessageHandler)(Dart_Port dest_port_id,
Dart_Port reply_port_id,
- uint8_t* data);
-// TODO(turnidge): Make this function take more appropriate arguments.
+ Dart_CMessage* message);
/**
* Creates a new native port. When messages are received on this
« no previous file with comments | « no previous file | runtime/vm/dart_api_impl_test.cc » ('j') | runtime/vm/growable_array.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698