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

Side by Side Diff: runtime/bin/eventhandler.cc

Issue 9875006: Remove unused thread pool from standalone VM binary. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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
« no previous file with comments | « runtime/bin/eventhandler.h ('k') | runtime/bin/eventhandler_linux.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "bin/dartutils.h" 5 #include "bin/dartutils.h"
6 #include "bin/eventhandler.h" 6 #include "bin/eventhandler.h"
7 7
8 #include "include/dart_api.h" 8 #include "include/dart_api.h"
9 9
10 10
11 static const intptr_t kNativeEventHandlerFieldIndex = 0; 11 static const intptr_t kNativeEventHandlerFieldIndex = 0;
12 12
13 ThreadPool* EventHandler::thread_pool_ = NULL;
14
15 /* 13 /*
16 * Returns the reference of the EventHandler stored in the native field. 14 * Returns the reference of the EventHandler stored in the native field.
17 */ 15 */
18 static EventHandler* GetEventHandler(Dart_Handle handle) { 16 static EventHandler* GetEventHandler(Dart_Handle handle) {
19 intptr_t value = 0; 17 intptr_t value = 0;
20 Dart_Handle result = Dart_GetNativeInstanceField( 18 Dart_Handle result = Dart_GetNativeInstanceField(
21 handle, kNativeEventHandlerFieldIndex, &value); 19 handle, kNativeEventHandlerFieldIndex, &value);
22 if (Dart_IsError(result)) { 20 if (Dart_IsError(result)) {
23 Dart_PropagateError(result); 21 Dart_PropagateError(result);
24 } 22 }
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 Dart_Handle handle = Dart_GetNativeArgument(args, 0); 60 Dart_Handle handle = Dart_GetNativeArgument(args, 0);
63 EventHandler* event_handler = GetEventHandler(handle); 61 EventHandler* event_handler = GetEventHandler(handle);
64 intptr_t id = DartUtils::GetIntegerValue(Dart_GetNativeArgument(args, 1)); 62 intptr_t id = DartUtils::GetIntegerValue(Dart_GetNativeArgument(args, 1));
65 handle = Dart_GetNativeArgument(args, 2); 63 handle = Dart_GetNativeArgument(args, 2);
66 Dart_Port dart_port = 64 Dart_Port dart_port =
67 DartUtils::GetIntegerField(handle, DartUtils::kIdFieldName); 65 DartUtils::GetIntegerField(handle, DartUtils::kIdFieldName);
68 intptr_t data = DartUtils::GetIntegerValue(Dart_GetNativeArgument(args, 3)); 66 intptr_t data = DartUtils::GetIntegerValue(Dart_GetNativeArgument(args, 3));
69 event_handler->SendData(id, dart_port, data); 67 event_handler->SendData(id, dart_port, data);
70 Dart_ExitScope(); 68 Dart_ExitScope();
71 } 69 }
OLDNEW
« no previous file with comments | « runtime/bin/eventhandler.h ('k') | runtime/bin/eventhandler_linux.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698