ITEM_TYPE_LISTBOX elements (Server browser, hilt selection, etc) can't be scrolled.
Whether you consider this a bug or not is totally your call. I like to scroll through lists
ui_shared.c -> Item_ListBox_HandleKey
After
Code:
if ( key == A_CURSOR_DOWN || key == A_KP_2 )
{
if (!listPtr->notselectable) {
listPtr->cursorPos++;
if (listPtr->cursorPos < listPtr->startPos) {
listPtr->startPos = listPtr->cursorPos;
//JLF
#ifndef _XBOX
return qfalse;
#endif
}
if (listPtr->cursorPos >= count) {
listPtr->cursorPos = count-1;
return qfalse;
}
if (listPtr->cursorPos >= listPtr->startPos + viewmax) {
listPtr->startPos = listPtr->cursorPos - viewmax + 1;
}
item->cursorPos = listPtr->cursorPos;
DC->feederSelection(item->special, item->cursorPos, NULL);
}
else {
listPtr->startPos++;
if (listPtr->startPos > max)
listPtr->startPos = max;
}
return qtrue;
}
Add
Code:
if ( key == A_MWHEELUP )
{
listPtr->startPos -= ((int)item->special == FEEDER_Q3HEADS) ? viewmax : 1;
if (listPtr->startPos < 0)
{
listPtr->startPos = 0;
Display_MouseMove(NULL, DC->cursorx, DC->cursory);
return qfalse;
}
Display_MouseMove(NULL, DC->cursorx, DC->cursory);
return qtrue;
}
if ( key == A_MWHEELDOWN )
{
listPtr->startPos += ((int)item->special == FEEDER_Q3HEADS) ? viewmax : 1;
if (listPtr->startPos > max)
{
listPtr->startPos = max;
Display_MouseMove(NULL, DC->cursorx, DC->cursory);
return qfalse;
}
Display_MouseMove(NULL, DC->cursorx, DC->cursory);
return qtrue;
}
Updated: Fixed for FEEDER_Q3HEADS to skip an entire row (16th October 2011)
Updated: return qfalse if there's no more to scroll, to prevent the sound from playing (10th November 2011)
Updated: Forcefully update the mouse position when scrolling so the proper listbox entry has focus (12th November 2011)