Fix redundant XQueryPointer() calls
On Linux, this is a blocking call that makes a round trip to the X server. On my machine (with a local X server), this call usually takes over 1ms (and much longer for a remote server!). This call gets made on every mouse motion event in the web contents, and in many other cases like tab dragging and DND. The issue is that value_or() was added in [1] which always calls GetCursorLocation(), even when the cached cursor location is available. [1] https://chromium-review.googlesource.com/c/chromium/src/+/2104428 BUG=None R=sky Change-Id: If2d0fd4bfb62927e4a408c4f3d5ccf72da8a0b81 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2128941 Commit-Queue: Thomas Anderson <thomasanderson@chromium.org> Commit-Queue: Peter Kasting <pkasting@chromium.org> Auto-Submit: Thomas Anderson <thomasanderson@chromium.org> Reviewed-by:Peter Kasting <pkasting@chromium.org> Cr-Commit-Position: refs/heads/master@{#754761}
Showing
Please register or sign in to comment