| 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
|
|
|