Introduction
Introduction Statistics Contact Development Disclaimer Help
tclean button selection code. - st - [fork] customized build of st, the simple …
git clone git://src.adamsgaard.dk/st
Log
Files
Refs
README
LICENSE
---
commit 3a50a4fd931ed58454b680c9fc5c1bc2278e67f3
parent 3470e3af23f4b98ce4293f6090c8df59a08329d9
Author: AurĂ©lien Aptel <[email protected]>
Date: Wed, 13 Oct 2010 00:50:18 +0200
clean button selection code.
Diffstat:
M st.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/st.c b/st.c
t@@ -243,8 +243,9 @@ static inline int selected(int x, int y) {
}
static void getbuttoninfo(XEvent *e, int *b, int *x, int *y) {
- if(b) *b = e->xbutton.state,
- *b=*b==4096?5:*b==2048?4:*b==1024?3:*b==512?2:*b==256?1:-1;
+ if(b)
+ *b = e->xbutton.button;
+
*x = e->xbutton.x/xw.cw;
*y = e->xbutton.y/xw.ch;
sel.b.x = sel.by < sel.ey ? sel.bx : sel.ex;
You are viewing proxied material from mx1.adamsgaard.dk. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.