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

Unified Diff: runtime/bin/eventhandler_macos.cc

Issue 9104041: Added API Dart_PostCMessage for posting a Dart_CMessage structure (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed review comments from asiva@ Created 8 years, 10 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
Index: runtime/bin/eventhandler_macos.cc
diff --git a/runtime/bin/eventhandler_macos.cc b/runtime/bin/eventhandler_macos.cc
index 188720ce7762fe8b144be3053e7dd7462b5d8730..65e34a62a097a74e792b1959087438bb861f7c5b 100644
--- a/runtime/bin/eventhandler_macos.cc
+++ b/runtime/bin/eventhandler_macos.cc
@@ -12,6 +12,7 @@
#include <sys/time.h>
#include <unistd.h>
+#include "bin/dartutils.h"
#include "bin/fdutils.h"
#include "bin/hashmap.h"
#include "platform/utils.h"
@@ -309,7 +310,7 @@ void EventHandlerImplementation::HandleEvents(struct pollfd* pollfds,
Dart_Port port = sd->port();
ASSERT(port != 0);
sd->Unregister();
- Dart_PostIntArray(port, 1, &event_mask);
+ DartUtils::PostInteger(port, event_mask);
}
}
}
@@ -330,7 +331,7 @@ void EventHandlerImplementation::HandleTimeout() {
if (timeout_ != kInfinityTimeout) {
intptr_t millis = timeout_ - GetCurrentTimeMilliseconds();
if (millis <= 0) {
- Dart_PostIntArray(timeout_port_, 0, NULL);
+ DartUtils::PostNull(timeout_port_);
timeout_ = kInfinityTimeout;
timeout_port_ = 0;
}

Powered by Google App Engine
This is Rietveld 408576698