News:

Come Chat with us live! Learn how HERE!

Main Menu

patch: mouse wheel in server browser

Started by rasz_pl, July 19, 2006, 12:02:16 PM

rasz_pl

patch for the latest SVN version of ui_shared.c. Mouse wheel scrolls 3 lines at a time. Now I'l patch sliders (gamma/volume and so on) to work with mousewheel.

Should I PM/email this to Timbo? tjw? What should I do with it beside bragging here on forum ? :)


--- ui_shared.c 2006-07-19 12:55:43.000000000 +0200
+++ ui_shared.c 2006-07-19 12:52:52.000000000 +0200
@@ -1834,20 +1834,6 @@
      }
    }
    // mouse hit
-    if (key == K_MWHEELUP) {
-        listPtr->startPos-=3;
-        if (listPtr->startPos < 0) {
-          listPtr->startPos = 0;
-        }
-      return qtrue;
-    }
-    if (key == K_MWHEELDOWN) {
-        listPtr->startPos+=3;
-        if (listPtr->startPos > max) {
-          listPtr->startPos = max;
-        }
-      return qtrue;
-    }
    if (key == K_MOUSE1 || key == K_MOUSE2) {
      if (item->window.flags & WINDOW_LB_LEFTARROW) {
        listPtr->startPos--;
@@ -2381,7 +2395,7 @@
      }
    }
  }
-  DC->Print("slider handle key exit\n");
+  #DC->Print("slider handle key exit\n");
  return qfalse;
}

vcxzet

I guess contacting via IRC is faster
how can i scroll down the player list
there is a scrollbar but it does not seem to work

rasz_pl

>I guess contacting via IRC is faster

hmm what server/channel? i'm a n00b when it comes to irc

>how can i scroll down the player list
>there is a scrollbar but it does not seem to work

you cant :P its non modal so you cant mouse over it, and if you cant mouse over it game wont handle any events for it, I can think about some solution if you like, hmm dedicated scroll player list keys for example

BTW my patch fixes every window with scrollbar that you can mouseover, so serverinfo is mousewhell scrollable too :)


EDIT
: there is a code in SVN  for scrolling scores
 { "scoresUp", CG_scrollScoresUp_f },
 { "scoresDown", CG_scrollScoresDown_f },

so it looks like all you have to do is
bind PGDN "scoresDown"
bind PGUP "scoresUp"

but cant check it (hard to find a >20 ppl server with latest SVN version :P)

EDIT2: No way i'm touching sliders, blah floats?? in simple slider? blah blah blah :)


Lava Croft

Do people actually use that bugged piece of crap they call a
'Server Browser'?

Started a Poll on this,

http://www.tremulous.net/phpBB2/viewtopic.php?t=1299

Teiman

Quote from: Lava CroftDo people actually use that bugged piece of crap they call a
'Server Browser'?

Yes.

Rekov

Quote from: Lava CroftDo people actually use that bugged piece of crap they call a
'Server Browser'?

Started a Poll on this,

http://www.tremulous.net/phpBB2/viewtopic.php?t=1299

Your poll should answer that question for you. Maybe instead of ridiculing people, you should provide and explain the fucntion of an alternative?

Lava Croft

I am not riducling people, and if anyone wants to use the 'Server Browser', they are free to do so, naturally. I was just curious as to if people used it at all. Also, maybe you should read the threads before you post, there already have been named several other ways of finding/connecting to servers. Why haven't you left for CS, er, NS anways?