From 9dd1558b2617a110a85fea8c476489cd7fbbf5e5 Mon Sep 17 00:00:00 2001 From: Enno Boland Date: Wed, 13 May 2015 15:54:39 +0200 Subject: [PATCH] drawterm: fix middle click emulation --- .../drawterm/patches/gui_x11_thirdbutton.diff | 18 ++++++++++++++++++ srcpkgs/drawterm/template | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/drawterm/patches/gui_x11_thirdbutton.diff diff --git a/srcpkgs/drawterm/patches/gui_x11_thirdbutton.diff b/srcpkgs/drawterm/patches/gui_x11_thirdbutton.diff new file mode 100644 index 00000000000..3656b1a0631 --- /dev/null +++ b/srcpkgs/drawterm/patches/gui_x11_thirdbutton.diff @@ -0,0 +1,18 @@ +https://bitbucket.org/rsc/drawterm/issue/7/drawterm-emulation-of-2-mouse-button-does#comment-16264332 +--- gui-x11/x11.c Sun Jan 02 18:33:44 2011 -0500 ++++ gui-x11/x11.c Sat May 05 01:00:27 2012 -0700 +@@ -1340,8 +1340,12 @@ + ms.buttons |= 1; + if(s & Button2Mask) + ms.buttons |= 2; +- if(s & Button3Mask) +- ms.buttons |= 4; ++ if(s & Button3Mask){ ++ if (s & ShiftMask) ++ ms.buttons |= 2; ++ else ++ ms.buttons |= 4; ++ } + if(s & Button4Mask) + ms.buttons |= 8; + if(s & Button5Mask) diff --git a/srcpkgs/drawterm/template b/srcpkgs/drawterm/template index d49afbfb6a0..b752a469b11 100644 --- a/srcpkgs/drawterm/template +++ b/srcpkgs/drawterm/template @@ -2,7 +2,7 @@ pkgname=drawterm version=0.0.20130621 _hghash=b4e2f62f737e -revision=1 +revision=2 makedepends="libX11-devel libXt-devel" short_desc="Connect to Plan 9 CPU servers from other operating systems" maintainer="Enno Boland "