]> de.git.xonotic.org Git - xonotic/darkplaces.git/commitdiff
use vid.conheight instead of scr_conlines in history scrolling
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 13 Jan 2005 06:17:26 +0000 (06:17 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 13 Jan 2005 06:17:26 +0000 (06:17 +0000)
don't call SCR_UpdateScreen twice

git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@4920 d7cf8633-e32d-0410-b094-e92efae38249

keys.c

diff --git a/keys.c b/keys.c
index 20211e7d1df49729f6169f0539a8ea96b1371eae..37f33affb851df013b02f7a200311384984034fc 100644 (file)
--- a/keys.c
+++ b/keys.c
@@ -319,10 +319,7 @@ Key_Console (int key, char ascii)
                key_linepos = 1;
                // force an update, because the command may take some time
                if (cls.state == ca_disconnected)
-               {
-                       CL_UpdateScreen ();
                        CL_UpdateScreen ();
-               }
                return;
        }
 
@@ -432,7 +429,7 @@ Key_Console (int key, char ascii)
 
        if (key == K_PGUP || key == K_KP_PGUP || key == K_MWHEELUP)
        {
-               con_backscroll += ((int) scr_conlines >> 4);
+               con_backscroll += ((int) vid.conheight >> 5);
                if (con_backscroll > con_totallines - (vid.conheight>>3) - 1)
                        con_backscroll = con_totallines - (vid.conheight>>3) - 1;
                return;
@@ -440,7 +437,7 @@ Key_Console (int key, char ascii)
 
        if (key == K_PGDN || key == K_KP_PGDN || key == K_MWHEELDOWN)
        {
-               con_backscroll -= ((int) scr_conlines >> 4);
+               con_backscroll -= ((int) vid.conheight >> 5);
                if (con_backscroll < 0)
                        con_backscroll = 0;
                return;