Title: [97831] trunk
- Revision
- 97831
- Author
- [email protected]
- Date
- 2011-10-18 21:32:28 -0700 (Tue, 18 Oct 2011)
Log Message
Source/WebCore: Implement NSProcessInfo::systemUptime on Mac Leopard.
https://bugs.webkit.org/show_bug.cgi?id=66577
Reviewed by Tony Chang.
* WebCore.gyp/WebCore.gyp:
* platform/chromium/ScrollAnimatorChromiumMac.mm:
(-[NSProcessInfo systemUptime]):
LayoutTests: Enable touch tests on Mac Leopard.
https://bugs.webkit.org/show_bug.cgi?id=66577
Reviewed by Tony Chang.
* platform/chromium/test_expectations.txt:
Modified Paths
Diff
Modified: trunk/LayoutTests/ChangeLog (97830 => 97831)
--- trunk/LayoutTests/ChangeLog 2011-10-19 03:55:25 UTC (rev 97830)
+++ trunk/LayoutTests/ChangeLog 2011-10-19 04:32:28 UTC (rev 97831)
@@ -1,3 +1,12 @@
+2011-10-18 Johnny Ding <[email protected]>
+
+ Enable touch tests on Mac Leopard.
+ https://bugs.webkit.org/show_bug.cgi?id=66577
+
+ Reviewed by Tony Chang.
+
+ * platform/chromium/test_expectations.txt:
+
2011-10-18 Ojan Vafai <[email protected]>
Unreviewed. New expected results after http://trac.webkit.org/changeset/97707.
Modified: trunk/LayoutTests/platform/chromium/test_expectations.txt (97830 => 97831)
--- trunk/LayoutTests/platform/chromium/test_expectations.txt 2011-10-19 03:55:25 UTC (rev 97830)
+++ trunk/LayoutTests/platform/chromium/test_expectations.txt 2011-10-19 04:32:28 UTC (rev 97831)
@@ -3474,13 +3474,6 @@
BUGWK66569 WIN RELEASE : http/tests/inspector/network/network-iframe-load-and-delete.html = TIMEOUT PASS
BUGWK66569 SLOW LINUX WIN DEBUG : http/tests/inspector/network/network-iframe-load-and-delete.html = PASS
-BUGWK66577 LEOPARD : fast/events/touch/basic-single-touch-events.html = TIMEOUT
-BUGWK66577 LEOPARD : fast/events/touch/multi-touch-grouped-targets.html = TIMEOUT
-BUGWK66577 LEOPARD : fast/events/touch/touch-gesture-scroll.html = TIMEOUT
-BUGWK66577 LEOPARD : fast/events/touch/touch-target-limited.html = TIMEOUT
-BUGWK66577 LEOPARD : fast/events/touch/touch-target.html = TIMEOUT
-BUGWK66577 LEOPARD : fast/events/touch/tap-highlight-color.html = TIMEOUT
-
BUGV8_1634 : fast/js/const.html = TEXT
BUGWK66730 WIN : http/tests/websocket/tests/hixie76/handshake-fail-by-no-connection-header.html = PASS TEXT
Modified: trunk/Source/WebCore/ChangeLog (97830 => 97831)
--- trunk/Source/WebCore/ChangeLog 2011-10-19 03:55:25 UTC (rev 97830)
+++ trunk/Source/WebCore/ChangeLog 2011-10-19 04:32:28 UTC (rev 97831)
@@ -1,3 +1,14 @@
+2011-10-18 Johnny Ding <[email protected]>
+
+ Implement NSProcessInfo::systemUptime on Mac Leopard.
+ https://bugs.webkit.org/show_bug.cgi?id=66577
+
+ Reviewed by Tony Chang.
+
+ * WebCore.gyp/WebCore.gyp:
+ * platform/chromium/ScrollAnimatorChromiumMac.mm:
+ (-[NSProcessInfo systemUptime]):
+
2011-10-18 Sam Weinig <[email protected]>
Try to jostle the windows build back to life.
Modified: trunk/Source/WebCore/WebCore.gyp/WebCore.gyp (97830 => 97831)
--- trunk/Source/WebCore/WebCore.gyp/WebCore.gyp 2011-10-19 03:55:25 UTC (rev 97830)
+++ trunk/Source/WebCore/WebCore.gyp/WebCore.gyp 2011-10-19 04:32:28 UTC (rev 97831)
@@ -1250,7 +1250,7 @@
'class_whitelist_regex':
'ChromiumWebCoreObjC|TCMVisibleView|RTCMFlippedView',
'category_whitelist_regex':
- 'TCMInterposing',
+ 'TCMInterposing|ScrollAnimatorChromiumMacExt',
},
'action': [
'mac/check_objc_rename.sh',
Modified: trunk/Source/WebCore/platform/chromium/ScrollAnimatorChromiumMac.mm (97830 => 97831)
--- trunk/Source/WebCore/platform/chromium/ScrollAnimatorChromiumMac.mm 2011-10-19 03:55:25 UTC (rev 97830)
+++ trunk/Source/WebCore/platform/chromium/ScrollAnimatorChromiumMac.mm 2011-10-19 04:32:28 UTC (rev 97831)
@@ -25,6 +25,9 @@
#include "config.h"
+#include <sys/time.h>
+#include <sys/sysctl.h>
+
#include "ScrollAnimatorChromiumMac.h"
#include "FloatPoint.h"
@@ -46,9 +49,31 @@
@protocol NSAnimationDelegate
@end
-@interface NSProcessInfo (NSObject)
+@interface NSProcessInfo (ScrollAnimatorChromiumMacExt)
- (NSTimeInterval)systemUptime;
@end
+
+@implementation NSProcessInfo (ScrollAnimatorChromiumMacExt)
+- (NSTimeInterval)systemUptime
+{
+ // Get how long system has been up. Found by looking getting "boottime" from the kernel.
+ static struct timeval boottime = {0};
+ if (!boottime.tv_sec) {
+ int mib[2] = {CTL_KERN, KERN_BOOTTIME};
+ size_t size = sizeof(boottime);
+ if (-1 == sysctl(mib, 2, &boottime, &size, 0, 0))
+ boottime.tv_sec = 0;
+ }
+ struct timeval now;
+ if (boottime.tv_sec && -1 != gettimeofday(&now, 0)) {
+ struct timeval uptime;
+ timersub(&now, &boottime, &uptime);
+ NSTimeInterval result = uptime.tv_sec + (uptime.tv_usec / 1E+6);
+ return result;
+ }
+ return 0;
+}
+@end
#endif
@interface NSObject (ScrollAnimationHelperDetails)
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes