mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 15:22:04 +00:00
rename the width parameter to lsize as it's the size of the input line, not
the drawn width
This commit is contained in:
parent
6d63d1d55b
commit
d1460f6166
2 changed files with 5 additions and 5 deletions
|
@ -102,7 +102,7 @@ void Con_BasicCompleteCommandLine (inputline_t *il);
|
|||
// formatted in columns on the console
|
||||
void Con_DisplayList(const char **list, int con_linewidth);
|
||||
|
||||
inputline_t *Con_CreateInputLine (int lines, int width, char prompt);
|
||||
inputline_t *Con_CreateInputLine (int lines, int lsize, char prompt);
|
||||
void Con_DestroyInputLine (inputline_t *inputline);
|
||||
void Con_ClearTyping (inputline_t *il);
|
||||
void Con_ProcessInputLine (inputline_t *il, int ch);
|
||||
|
|
|
@ -48,7 +48,7 @@ static const char rcsid[] =
|
|||
#include "compat.h"
|
||||
|
||||
struct inputline_s *
|
||||
Con_CreateInputLine (int lines, int width, char prompt)
|
||||
Con_CreateInputLine (int lines, int lsize, char prompt)
|
||||
{
|
||||
char *l, **p;
|
||||
int size;
|
||||
|
@ -57,7 +57,7 @@ Con_CreateInputLine (int lines, int width, char prompt)
|
|||
|
||||
size = sizeof (inputline_t); // space for the header
|
||||
size += sizeof (char *[lines]); // space for the line pointers
|
||||
size += lines * width; // space for the lines themselves
|
||||
size += lines * lsize; // space for the lines themselves
|
||||
|
||||
inputline = calloc (1, size);
|
||||
p = (char**)(inputline + 1);
|
||||
|
@ -65,10 +65,10 @@ Con_CreateInputLine (int lines, int width, char prompt)
|
|||
|
||||
inputline->lines = p;
|
||||
inputline->num_lines = lines;
|
||||
inputline->line_size = width;
|
||||
inputline->line_size = lsize;
|
||||
while (lines--) {
|
||||
*p++ = l;
|
||||
l += width;
|
||||
l += lsize;
|
||||
}
|
||||
inputline->prompt_char = prompt;
|
||||
|
||||
|
|
Loading…
Reference in a new issue