x11: Fix crash when coalescing XEvents
After crrev.com/c/2022280, logic for coalescing XEvents has been moved to ui::X11Window [1], there are cases where translating coalesced XEvent results in ET_UNKNOWN events. Before migrating away from PlatformEvent based ui::*Event ctors to XEvent translation helper functions, handling such cases was a matter of checking its ::type() value, now translation functions return nullptr instead, so update this checking accordingly. [1] https://crrev.com/c/2022280/18/ui/base/x/x11_window.cc#b1196 R=thomasanderson@chromium.org Bug: 1052293, 1052301 Test: Run with ozone/x11 backend, scroll, browser should not crashed Change-Id: Icf415ce72e679f39598f9d72ad098d56217e21da Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2057072 Commit-Queue: Scott Violet <sky@chromium.org> Auto-Submit: Nick Yamane <nickdiego@igalia.com> Reviewed-by:Scott Violet <sky@chromium.org> Reviewed-by:
Thomas Anderson <thomasanderson@chromium.org> Cr-Commit-Position: refs/heads/master@{#741602}
Showing
Please register or sign in to comment