X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fthird_party%2FWebKit%2FSource%2Fweb%2FWebKit.cpp;h=20d46b142af65a7a0af47ea59de1706c38c91ce0;hb=ff3e2503a20db9193d323c1d19c38c68004dec4a;hp=188b902232dde4fe11b214b127471d5166af117c;hpb=7338fba38ba696536d1cc9d389afd716a6ab2fe6;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/third_party/WebKit/Source/web/WebKit.cpp b/src/third_party/WebKit/Source/web/WebKit.cpp index 188b902..20d46b1 100644 --- a/src/third_party/WebKit/Source/web/WebKit.cpp +++ b/src/third_party/WebKit/Source/web/WebKit.cpp @@ -76,11 +76,9 @@ public: } // namespace static WebThread::TaskObserver* s_endOfTaskRunner = 0; -#if ENABLE(OILPAN) static WebThread::TaskObserver* s_pendingGCRunner = 0; static WebCore::ThreadState::Interruptor* s_messageLoopInterruptor = 0; static WebCore::ThreadState::Interruptor* s_isolateInterruptor = 0; -#endif // Make sure we are not re-initialized in the same address space. // Doing so may cause hard to reproduce crashes. @@ -111,13 +109,10 @@ void initialize(Platform* platform) v8::V8::SetEntropySource(&generateEntropy); v8::V8::SetArrayBufferAllocator(WebCore::v8ArrayBufferAllocator()); v8::V8::Initialize(); - WebCore::setMainThreadIsolate(isolate); WebCore::V8PerIsolateData::ensureInitialized(isolate); -#if ENABLE(OILPAN) s_isolateInterruptor = new WebCore::V8IsolateInterruptor(v8::Isolate::GetCurrent()); WebCore::ThreadState::current()->addInterruptor(s_isolateInterruptor); -#endif // currentThread will always be non-null in production, but can be null in Chromium unit tests. if (WebThread* currentThread = platform->currentThread()) { @@ -132,7 +127,7 @@ void initialize(Platform* platform) v8::Isolate* mainThreadIsolate() { - return WebCore::mainThreadIsolate(); + return WebCore::V8PerIsolateData::mainThreadIsolate(); } static double currentTimeFunction() @@ -166,7 +161,6 @@ void initializeWithoutV8(Platform* platform) WTF::setRandomSource(cryptographicallyRandomValues); WTF::initialize(currentTimeFunction, monotonicallyIncreasingTimeFunction); WTF::initializeMainThread(callOnMainThreadFunction); -#if ENABLE(OILPAN) WebCore::Heap::init(); if (WebThread* currentThread = platform->currentThread()) { ASSERT(!s_pendingGCRunner); @@ -177,7 +171,6 @@ void initializeWithoutV8(Platform* platform) s_messageLoopInterruptor = new WebCore::MessageLoopInterruptor(currentThread); WebCore::ThreadState::current()->addInterruptor(s_messageLoopInterruptor); } -#endif WebCore::init(); WebCore::ImageDecodingStore::initializeOnce(); @@ -208,13 +201,10 @@ void shutdown() s_endOfTaskRunner = 0; } -#if ENABLE(OILPAN) ASSERT(s_isolateInterruptor); WebCore::ThreadState::current()->removeInterruptor(s_isolateInterruptor); -#endif - WebCore::V8PerIsolateData::dispose(WebCore::mainThreadIsolate()); - WebCore::setMainThreadIsolate(0); + WebCore::V8PerIsolateData::dispose(WebCore::V8PerIsolateData::mainThreadIsolate()); v8::V8::Dispose(); shutdownWithoutV8(); @@ -225,7 +215,6 @@ void shutdownWithoutV8() ASSERT(!s_endOfTaskRunner); WebCore::ImageDecodingStore::shutdown(); WebCore::shutdown(); -#if ENABLE(OILPAN) if (Platform::current()->currentThread()) { ASSERT(s_pendingGCRunner); delete s_pendingGCRunner; @@ -237,7 +226,6 @@ void shutdownWithoutV8() s_messageLoopInterruptor = 0; } WebCore::Heap::shutdown(); -#endif WTF::shutdown(); Platform::shutdown(); WebPrerenderingSupport::shutdown();