Title: [102368] trunk/Source/WebCore
Revision
102368
Author
[email protected]
Date
2011-12-08 12:53:05 -0800 (Thu, 08 Dec 2011)

Log Message

Add a platform EventLoop for iOS
https://bugs.webkit.org/show_bug.cgi?id=74043

Patch by Benjamin Poulain <[email protected]> on 2011-12-08
Reviewed by David Kilzer.

* WebCore.xcodeproj/project.pbxproj:
* platform/ios/EventLoopIOS.mm: Added.
(WebCore::EventLoop::cycle):

Modified Paths

Added Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (102367 => 102368)


--- trunk/Source/WebCore/ChangeLog	2011-12-08 20:47:11 UTC (rev 102367)
+++ trunk/Source/WebCore/ChangeLog	2011-12-08 20:53:05 UTC (rev 102368)
@@ -1,3 +1,14 @@
+2011-12-08  Benjamin Poulain  <[email protected]>
+
+        Add a platform EventLoop for iOS
+        https://bugs.webkit.org/show_bug.cgi?id=74043
+
+        Reviewed by David Kilzer.
+
+        * WebCore.xcodeproj/project.pbxproj:
+        * platform/ios/EventLoopIOS.mm: Added.
+        (WebCore::EventLoop::cycle):
+
 2011-12-08  Pavel Feldman  <[email protected]>
 
         Web Inspector: return node counts on the document / detached root basis

Modified: trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj (102367 => 102368)


--- trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj	2011-12-08 20:47:11 UTC (rev 102367)
+++ trunk/Source/WebCore/WebCore.xcodeproj/project.pbxproj	2011-12-08 20:53:05 UTC (rev 102368)
@@ -679,6 +679,7 @@
 		2655413A1489811C000DFC5D /* KeyEventIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 265541381489811C000DFC5D /* KeyEventIOS.mm */; };
 		265541521489B233000DFC5D /* CursorIOS.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2655414B1489AA2B000DFC5D /* CursorIOS.cpp */; };
 		26E98A10130A9FCA008EB7B2 /* TextCodecASCIIFastPath.h in Headers */ = {isa = PBXBuildFile; fileRef = 26E98A0F130A9FCA008EB7B2 /* TextCodecASCIIFastPath.h */; };
+		26F40D4A14904A6300CA67C4 /* EventLoopIOS.mm in Sources */ = {isa = PBXBuildFile; fileRef = 26F40D4914904A6300CA67C4 /* EventLoopIOS.mm */; };
 		2917B5611473496C0052C9D0 /* LayerFlushScheduler.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 2917B55E1473496C0052C9D0 /* LayerFlushScheduler.cpp */; };
 		2917B5621473496C0052C9D0 /* LayerFlushScheduler.h in Headers */ = {isa = PBXBuildFile; fileRef = 2917B55F1473496C0052C9D0 /* LayerFlushScheduler.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		2917B5631473496C0052C9D0 /* LayerFlushSchedulerClient.h in Headers */ = {isa = PBXBuildFile; fileRef = 2917B5601473496C0052C9D0 /* LayerFlushSchedulerClient.h */; settings = {ATTRIBUTES = (Private, ); }; };
@@ -7786,6 +7787,7 @@
 		265541381489811C000DFC5D /* KeyEventIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = KeyEventIOS.mm; path = ios/KeyEventIOS.mm; sourceTree = "<group>"; };
 		2655414B1489AA2B000DFC5D /* CursorIOS.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = CursorIOS.cpp; path = ios/CursorIOS.cpp; sourceTree = "<group>"; };
 		26E98A0F130A9FCA008EB7B2 /* TextCodecASCIIFastPath.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = TextCodecASCIIFastPath.h; sourceTree = "<group>"; };
+		26F40D4914904A6300CA67C4 /* EventLoopIOS.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = EventLoopIOS.mm; path = ios/EventLoopIOS.mm; sourceTree = "<group>"; };
 		2917B55E1473496C0052C9D0 /* LayerFlushScheduler.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; name = LayerFlushScheduler.cpp; path = ca/LayerFlushScheduler.cpp; sourceTree = "<group>"; };
 		2917B55F1473496C0052C9D0 /* LayerFlushScheduler.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LayerFlushScheduler.h; path = ca/LayerFlushScheduler.h; sourceTree = "<group>"; };
 		2917B5601473496C0052C9D0 /* LayerFlushSchedulerClient.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = LayerFlushSchedulerClient.h; path = ca/LayerFlushSchedulerClient.h; sourceTree = "<group>"; };
@@ -17625,6 +17627,7 @@
 		A59E3C1B11580F340072928E /* ios */ = {
 			isa = PBXGroup;
 			children = (
+				26F40D4914904A6300CA67C4 /* EventLoopIOS.mm */,
 				2655414B1489AA2B000DFC5D /* CursorIOS.cpp */,
 				265541371489811C000DFC5D /* KeyEventCodesIOS.h */,
 				265541381489811C000DFC5D /* KeyEventIOS.mm */,
@@ -27654,6 +27657,7 @@
 				6E3FAD3814733F4000E42306 /* JSWebGLCompressedTextures.cpp in Sources */,
 				6E3FAE8E14733FDB00E42306 /* WebGLCompressedTextures.cpp in Sources */,
 				2655413A1489811C000DFC5D /* KeyEventIOS.mm in Sources */,
+				26F40D4A14904A6300CA67C4 /* EventLoopIOS.mm in Sources */,
 				D7613A501474F13F00DB8606 /* WebKitNamedFlow.cpp in Sources */,
 				D7613AC414753E5600DB8606 /* JSWebKitNamedFlow.cpp in Sources */,
 				8A195933147EA16E00D1EA61 /* DOMWebKitNamedFlow.mm in Sources */,

Added: trunk/Source/WebCore/platform/ios/EventLoopIOS.mm (0 => 102368)


--- trunk/Source/WebCore/platform/ios/EventLoopIOS.mm	                        (rev 0)
+++ trunk/Source/WebCore/platform/ios/EventLoopIOS.mm	2011-12-08 20:53:05 UTC (rev 102368)
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 2011 Apple Inc. All Rights Reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
+ * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL APPLE INC. OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
+ * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include "config.h"
+#include "EventLoop.h"
+
+#include <CoreFoundation/CFRunLoop.h>
+
+namespace WebCore {
+
+void EventLoop::cycle()
+{
+    CFTimeInterval timeInterval = 0.05;
+    CFRunLoopRunInMode(kCFRunLoopDefaultMode, timeInterval, true);
+}
+
+} // namespace WebCore
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to