wmii

git clone git://oldgit.suckless.org/wmii/
Log | Files | Refs | README | LICENSE

commit 32da5363cdca6ffb48df286ac70689ff22c793f3
parent 80c337d10cf3a5df5c0f0b1ce4b2b0b5a797ddef
Author: Anselm R. Garbe <garbeam@wmii.de>
Date:   Fri, 30 Jun 2006 14:29:49 +0200

fixed reverse selection from the end (curstart==nil)


Diffstat:
liblitz/input.c | 10++++++----
1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/liblitz/input.c b/liblitz/input.c @@ -82,6 +82,10 @@ blitz_draw_input(BlitzInput *i) end = i->curstart; } } + else if(i->curend) { /* && !i->curstart */ + start = i->curend; + end = nil; + } /* draw normal text */ xchangegc(i, &i->color, False); @@ -171,8 +175,7 @@ blitz_brelease_input(BlitzInput *i, int x, int y) { char *oend; - if(!(i->drag = blitz_ispointinrect(x, y, &i->rect)) || - !i->curstart) + if(!(i->drag = blitz_ispointinrect(x, y, &i->rect))) return False; oend = i->curend; i->curend = charof(i, x, y); @@ -185,8 +188,7 @@ blitz_bmotion_input(BlitzInput *i, int x, int y) { char *oend; - if(!i->drag || !(i->drag = blitz_ispointinrect(x, y, &i->rect)) - || !i->curstart) + if(!i->drag || !(i->drag = blitz_ispointinrect(x, y, &i->rect))) return False; oend = i->curend;