OLD | NEW |
1 // Copyright 2011, Google Inc. | 1 // Copyright 2011, Google Inc. |
2 // All rights reserved. | 2 // All rights reserved. |
3 // | 3 // |
4 // Redistribution and use in source and binary forms, with or without | 4 // Redistribution and use in source and binary forms, with or without |
5 // modification, are permitted provided that the following conditions are | 5 // modification, are permitted provided that the following conditions are |
6 // met: | 6 // met: |
7 // | 7 // |
8 // * Redistributions of source code must retain the above copyright | 8 // * Redistributions of source code must retain the above copyright |
9 // notice, this list of conditions and the following disclaimer. | 9 // notice, this list of conditions and the following disclaimer. |
10 // * Redistributions in binary form must reproduce the above | 10 // * Redistributions in binary form must reproduce the above |
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
86 static DartController* retrieve(ExecutionContext*); | 86 static DartController* retrieve(ExecutionContext*); |
87 | 87 |
88 bool isActive() { return !m_isolates.isEmpty(); } | 88 bool isActive() { return !m_isolates.isEmpty(); } |
89 | 89 |
90 void spawnDomUri(const String& uri); | 90 void spawnDomUri(const String& uri); |
91 | 91 |
92 private: | 92 private: |
93 static void initVMIfNeeded(); | 93 static void initVMIfNeeded(); |
94 | 94 |
95 static Dart_Isolate createIsolate(const char* scriptURL, const char* entryPo
int, Document*, bool isDOMEnabled, bool isDebuggerEnabled, char** errorMessage); | 95 static Dart_Isolate createIsolate(const char* scriptURL, const char* entryPo
int, Document*, bool isDOMEnabled, bool isDebuggerEnabled, char** errorMessage); |
96 static void shutdownIsolate(Dart_Isolate); | 96 void shutdownIsolate(Dart_Isolate); |
97 | 97 |
98 Dart_Isolate createDOMEnabledIsolate(const String& scriptURL, const String&
entryPoint, Document*); | 98 Dart_Isolate createDOMEnabledIsolate(const String& scriptURL, const String&
entryPoint, Document*); |
99 void scheduleScriptExecution(const String&, Dart_Isolate, PassRefPtr<DartAsy
ncLoader>, PassRefPtr<DartScriptInfo>); | 99 void scheduleScriptExecution(const String&, Dart_Isolate, PassRefPtr<DartAsy
ncLoader>, PassRefPtr<DartScriptInfo>); |
100 void loadAndRunScript(const String&, Dart_Isolate, PassRefPtr<DartAsyncLoade
r>, PassRefPtr<DartScriptInfo>); | 100 void loadAndRunScript(const String&, Dart_Isolate, PassRefPtr<DartAsyncLoade
r>, PassRefPtr<DartScriptInfo>); |
101 static void shutdownIsolateCallback(void* data); | 101 static void shutdownIsolateCallback(void* data); |
102 static Dart_Isolate createServiceIsolateCallback(void* callbackData, char**
error); | 102 static Dart_Isolate createServiceIsolateCallback(void* callbackData, char**
error); |
103 static Dart_Isolate createPureIsolateCallback(const char* prefix, const char
* main, void* callbackData, char** errorMsg); | 103 static Dart_Isolate createPureIsolateCallback(const char* prefix, const char
* main, void* callbackData, char** errorMsg); |
104 | 104 |
105 static void weakCallback(void* isolateCallbackData, Dart_WeakPersistentHandl
e, void* peer); | 105 static void weakCallback(void* isolateCallbackData, Dart_WeakPersistentHandl
e, void* peer); |
106 | 106 |
(...skipping 16 matching lines...) Expand all Loading... |
123 NPObjectMap m_npObjectMap; | 123 NPObjectMap m_npObjectMap; |
124 | 124 |
125 friend class DartDomLoadCallback; | 125 friend class DartDomLoadCallback; |
126 friend class DartScriptRunner; | 126 friend class DartScriptRunner; |
127 friend class DartService; | 127 friend class DartService; |
128 }; | 128 }; |
129 | 129 |
130 } | 130 } |
131 | 131 |
132 #endif // DartController_h | 132 #endif // DartController_h |
OLD | NEW |