Unreviewed, rolling out r167700.
[WebKit-https.git] / Source / WebKit2 / UIProcess / mac / PageClientImpl.mm
index 9a1e75e1f8318b6861eddec09d28d87d4c38e47d..81c19c7f4c62687a54973b5e27865b12316177d1 100644 (file)
@@ -324,7 +324,10 @@ void PageClientImpl::setCursor(const WebCore::Cursor& cursor)
         return;
 
     NSWindow *window = [m_wkView window];
-    if (!window || ![window isKeyWindow])
+    if (!window)
+        return;
+
+    if ([window windowNumber] != [NSWindow windowNumberAtPoint:[NSEvent mouseLocation] belowWindowWithWindowNumber:0])
         return;
 
     NSCursor *platformCursor = cursor.platformCursor();