Reviewed by Eric Seidel
authorsullivan <sullivan@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 28 Feb 2006 18:48:16 +0000 (18:48 +0000)
committersullivan <sullivan@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 28 Feb 2006 18:48:16 +0000 (18:48 +0000)
        Wean WebKit from one more SPI call. We learned about this new-to-Tiger
        API from filing Radar 4433222.

        * WebView/WebHTMLView.m:
        (-[WebHTMLView _autoscroll]):
        use public CGEventSourceButtonState() instead of WKMouseIsDown() (which was using SPI internally)

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@13055 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKit/ChangeLog
WebKit/WebView/WebHTMLView.m

index a797fe0..b397316 100644 (file)
@@ -1,3 +1,14 @@
+2006-02-28  John Sullivan  <sullivan@apple.com>
+
+        Reviewed by Eric Seidel
+        
+        Wean WebKit from one more SPI call. We learned about this new-to-Tiger
+        API from filing Radar 4433222.
+
+        * WebView/WebHTMLView.m:
+        (-[WebHTMLView _autoscroll]):
+        use public CGEventSourceButtonState() instead of WKMouseIsDown() (which was using SPI internally)
+
 2006-02-27  Tim Omernick  <timo@apple.com>
 
         Reviewed by Adele.
index e8a90f7..134e8ff 100644 (file)
@@ -28,6 +28,7 @@
 
 #import <WebKit/WebHTMLView.h>
 
+#import <ApplicationServices/ApplicationServices.h>
 #import <WebKit/DOM.h>
 #import <WebKit/DOMExtensions.h>
 #import <WebKit/DOMPrivate.h>
@@ -1407,7 +1408,7 @@ static WebHTMLView *lastHitView = nil;
 {
     // Guarantee that the autoscroll timer is invalidated, even if we don't receive
     // a mouse up event.
-    BOOL isStillDown = WKMouseIsDown();   
+    BOOL isStillDown = CGEventSourceButtonState(kCGEventSourceStateCombinedSessionState, kCGMouseButtonLeft);   
     if (!isStillDown){
         [self _stopAutoscrollTimer];
         return;