If the cursor-definition is missing from the menu, put cursor to the end of the last line of the banner.
git-svn-id: svn://katsu.triplehelix.org/dgamelaunch/trunk@447 db0b04b0-f4d1-0310-9a6d-de3e77497b0e
This commit is contained in:
parent
fb8bfdf5d4
commit
5d0bfc1b21
|
@ -315,9 +315,13 @@ loadbanner (char *fname, struct dg_banner *ban)
|
|||
while (fgets (buf, 80, bannerfile) != NULL)
|
||||
{
|
||||
char bufnew[80];
|
||||
int slen;
|
||||
|
||||
memset (bufnew, 0, 80);
|
||||
|
||||
slen = strlen(buf);
|
||||
if ((slen > 0) && (buf[slen-1] == '\n')) buf[slen-1] = '\0';
|
||||
|
||||
ban->len++;
|
||||
ban->lines = realloc (ban->lines, sizeof (char *) * ban->len);
|
||||
|
||||
|
|
|
@ -133,7 +133,9 @@ menu["mainmenu_user"] {
|
|||
# the file must be inside the chroot.
|
||||
bannerfile = "dgl_menu_main_user.txt"
|
||||
# after which cursor is moved to this location
|
||||
cursor = (5,18)
|
||||
# if cursor-definition is missing, the cursor is put
|
||||
# to the end of the last line of the banner.
|
||||
# cursor = (5,18)
|
||||
# keys we accept. format is
|
||||
# commands["string_of_keys"] = <commandlist>
|
||||
# for example, you could use commands["qQ"] = quit
|
||||
|
|
Loading…
Reference in New Issue