Changeset 52503 in webkit
- Timestamp:
- Dec 22, 2009 2:33:31 PM (14 years ago)
- Location:
- trunk/JavaScriptCore
- Files:
-
- 3 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/ChangeLog
r52500 r52503 1 2009-12-22 Steve Block <steveblock@google.com> 2 3 Reviewed by David Levin. 4 5 Updates Android's scheduleDispatchFunctionsOnMainThread() to use new 6 AndroidThreading class, rather than using JavaSharedClient directly. 7 This fixes the current layering violation. 8 https://bugs.webkit.org/show_bug.cgi?id=32651 9 10 The pattern is copied from Chromium, which uses the ChromiumThreading 11 class. This patch also fixes the style in ChromiumThreading.h. 12 13 * wtf/android/AndroidThreading.h: Added. Declares AndroidThreading. 14 * wtf/android/MainThreadAndroid.cpp: Modified 15 (WTF::scheduleDispatchFunctionsOnMainThread): Uses AndroidThreading. 16 * wtf/chromium/ChromiumThreading.h: Modified. Fixes style. 17 1 18 2009-12-22 Gavin Barraclough <barraclough@apple.com> 2 19 -
trunk/JavaScriptCore/wtf/android/AndroidThreading.h
r52502 r52503 24 24 */ 25 25 26 #include "config.h" 27 #include "MainThread.h" 28 29 #include "JavaSharedClient.h" 30 31 using namespace android; 26 #ifndef AndroidThreading_h 27 #define AndroidThreading_h 32 28 33 29 namespace WTF { 34 30 35 // Callback in the main thread. 36 static void timeoutFired(void*) 37 { 38 dispatchFunctionsFromMainThread(); 39 } 40 41 void initializeMainThreadPlatform() 42 { 43 } 44 45 void scheduleDispatchFunctionsOnMainThread() 46 { 47 JavaSharedClient::EnqueueFunctionPtr(timeoutFired, 0); 48 } 31 // An interface to the embedding layer, which provides threading support. 32 class AndroidThreading { 33 public: 34 static void scheduleDispatchFunctionsOnMainThread(); 35 }; 49 36 50 37 } // namespace WTF 38 39 #endif // AndroidThreading_h -
trunk/JavaScriptCore/wtf/android/MainThreadAndroid.cpp
r51323 r52503 27 27 #include "MainThread.h" 28 28 29 #include "JavaSharedClient.h" 30 31 using namespace android; 29 #include "AndroidThreading.h" 32 30 33 31 namespace WTF { 34 35 // Callback in the main thread.36 static void timeoutFired(void*)37 {38 dispatchFunctionsFromMainThread();39 }40 32 41 33 void initializeMainThreadPlatform() … … 45 37 void scheduleDispatchFunctionsOnMainThread() 46 38 { 47 JavaSharedClient::EnqueueFunctionPtr(timeoutFired, 0);39 AndroidThreading::scheduleDispatchFunctionsOnMainThread(); 48 40 } 49 41 -
trunk/JavaScriptCore/wtf/chromium/ChromiumThreading.h
r40684 r52503 34 34 namespace WTF { 35 35 36 37 38 39 40 41 36 // An interface to the embedding layer, which provides threading support. 37 class ChromiumThreading { 38 public: 39 static void initializeMainThread(); 40 static void scheduleDispatchFunctionsOnMainThread(); 41 }; 42 42 43 43 } // namespace WTF
Note: See TracChangeset
for help on using the changeset viewer.