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

Unified Diff: sky/engine/bindings-dart/core/dart/DartJsInteropData.h

Issue 875013003: Import Dart bindings as of Blink r188698. This merely copies the files over and does not attach any… (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 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
Index: sky/engine/bindings-dart/core/dart/DartJsInteropData.h
diff --git a/sky/engine/platform/PlatformThreadData.h b/sky/engine/bindings-dart/core/dart/DartJsInteropData.h
similarity index 71%
copy from sky/engine/platform/PlatformThreadData.h
copy to sky/engine/bindings-dart/core/dart/DartJsInteropData.h
index e00e1e56d9b5fdbadcc620579c6324f4cdd3a23e..653f4d3ba3b5dc4cceb88c2872694b90c25261ac 100644
--- a/sky/engine/platform/PlatformThreadData.h
+++ b/sky/engine/bindings-dart/core/dart/DartJsInteropData.h
@@ -28,32 +28,31 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef SKY_ENGINE_PLATFORM_PLATFORMTHREADDATA_H_
-#define SKY_ENGINE_PLATFORM_PLATFORMTHREADDATA_H_
+#ifndef DartJsInteropData_h
+#define DartJsInteropData_h
-#include "sky/engine/platform/PlatformExport.h"
-#include "sky/engine/wtf/Noncopyable.h"
-#include "sky/engine/wtf/OwnPtr.h"
+#include "wtf/RefCounted.h"
-namespace blink {
+#include <v8.h>
-class ThreadTimers;
+namespace blink {
-class PLATFORM_EXPORT PlatformThreadData {
- WTF_MAKE_NONCOPYABLE(PlatformThreadData);
+class DartJsInteropData {
public:
- PlatformThreadData();
- ~PlatformThreadData();
+ v8::Local<v8::Function> captureThisFunction();
+ v8::Local<v8::Function> wrapDartFunction();
+ v8::Local<v8::Function> instanceofFunction();
- ThreadTimers& threadTimers() { return *m_threadTimers; }
+private:
+ static v8::Local<v8::Function> cacheFunction(v8::Persistent<v8::Function>* cache, const char* scriptSrc);
- static PlatformThreadData& current();
- void destroy();
+ v8::Persistent<v8::Function> m_captureThisFunction;
+ v8::Persistent<v8::Function> m_wrapDartFunction;
+ v8::Persistent<v8::Function> m_instanceofFunction;
-private:
- OwnPtr<ThreadTimers> m_threadTimers;
+ // FIXME: add maps of Dart to V8 and V8 to Dart objects.
};
-} // namespace blink
+}
-#endif // SKY_ENGINE_PLATFORM_PLATFORMTHREADDATA_H_
+#endif // DartJsInteropData_h
« no previous file with comments | « sky/engine/bindings-dart/core/dart/DartJsInterop.cpp ('k') | sky/engine/bindings-dart/core/dart/DartJsInteropData.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698