|
|
@ -200,11 +200,13 @@ kpress(XKeyEvent * e) { |
|
|
|
} |
|
|
|
} |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_End: |
|
|
|
case XK_End: |
|
|
|
|
|
|
|
if(!sel) |
|
|
|
|
|
|
|
return; |
|
|
|
while(next) { |
|
|
|
while(next) { |
|
|
|
sel = curr = next; |
|
|
|
sel = curr = next; |
|
|
|
calcoffsets(); |
|
|
|
calcoffsets(); |
|
|
|
} |
|
|
|
} |
|
|
|
while(sel->right) |
|
|
|
while(sel && sel->right) |
|
|
|
sel = sel->right; |
|
|
|
sel = sel->right; |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_Escape: |
|
|
|
case XK_Escape: |
|
|
@ -212,6 +214,8 @@ kpress(XKeyEvent * e) { |
|
|
|
running = False; |
|
|
|
running = False; |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_Home: |
|
|
|
case XK_Home: |
|
|
|
|
|
|
|
if(!item) |
|
|
|
|
|
|
|
return; |
|
|
|
sel = curr = item; |
|
|
|
sel = curr = item; |
|
|
|
calcoffsets(); |
|
|
|
calcoffsets(); |
|
|
|
break; |
|
|
|
break; |
|
|
@ -225,16 +229,16 @@ kpress(XKeyEvent * e) { |
|
|
|
} |
|
|
|
} |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_Next: |
|
|
|
case XK_Next: |
|
|
|
if(next) { |
|
|
|
if(!next) |
|
|
|
sel = curr = next; |
|
|
|
return; |
|
|
|
calcoffsets(); |
|
|
|
sel = curr = next; |
|
|
|
} |
|
|
|
calcoffsets(); |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_Prior: |
|
|
|
case XK_Prior: |
|
|
|
if(prev) { |
|
|
|
if(!prev) |
|
|
|
sel = curr = prev; |
|
|
|
return; |
|
|
|
calcoffsets(); |
|
|
|
sel = curr = prev; |
|
|
|
} |
|
|
|
calcoffsets(); |
|
|
|
break; |
|
|
|
break; |
|
|
|
case XK_Return: |
|
|
|
case XK_Return: |
|
|
|
if((e->state & ShiftMask) && text) |
|
|
|
if((e->state & ShiftMask) && text) |
|
|
|