From 5d9c07d9d81adb35fc6fc2bcf32fa1c64ce079ac Mon Sep 17 00:00:00 2001 From: jk Date: Tue, 27 Oct 2020 19:21:00 -0500 Subject: upgpkg: ungoogled-chromium 86.0.4240.111-2 --- xproto-fix-underflow-in-Fp1616ToDouble.patch | 37 ++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 xproto-fix-underflow-in-Fp1616ToDouble.patch (limited to 'xproto-fix-underflow-in-Fp1616ToDouble.patch') diff --git a/xproto-fix-underflow-in-Fp1616ToDouble.patch b/xproto-fix-underflow-in-Fp1616ToDouble.patch new file mode 100644 index 0000000..8fcbd72 --- /dev/null +++ b/xproto-fix-underflow-in-Fp1616ToDouble.patch @@ -0,0 +1,37 @@ +From 5ade494a9966c7a9675af86dc42aca62fb4d806d Mon Sep 17 00:00:00 2001 +From: Tom Anderson +Date: Wed, 21 Oct 2020 22:02:35 +0000 +Subject: [PATCH] [XProto] Fix underflow in Fp1616ToDouble + +x11::Input::Fp1616 should be treated as a signed integer, otherwise +-1 will underflow to 65535. When dragging a scrollbar, this would +cause the scrollbar to snap to the bottom when the cursor is dragged +above the window's y=0 coordinate. Verified that the issue is fixed +after this CL. + +BUG=1139623,1136352 +R=sky + +Change-Id: Ie318006ceadde9b9ce3e267fb453ddeba0e81da0 +Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2485620 +Auto-Submit: Thomas Anderson +Commit-Queue: Scott Violet +Reviewed-by: Scott Violet +Cr-Commit-Position: refs/heads/master@{#819538} +--- + ui/events/x/events_x_utils.cc | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/ui/events/x/events_x_utils.cc b/ui/events/x/events_x_utils.cc +index 3010db5f40c..856dfb221e7 100644 +--- a/ui/events/x/events_x_utils.cc ++++ b/ui/events/x/events_x_utils.cc +@@ -376,7 +376,7 @@ base::TimeTicks TimeTicksFromXEvent(const x11::Event& xev) { + + // This is ported from libxi's FP1616toDBL in XExtInt.c + double Fp1616ToDouble(x11::Input::Fp1616 x) { +- auto x32 = static_cast(x); ++ auto x32 = static_cast(x); + return x32 * 1.0 / (1 << 16); + } + -- cgit v1.2.3