Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/lib/libmenu Remove the resetting of top_row, cur_item and th...



details:   https://anonhg.NetBSD.org/src/rev/91a9f1f9df20
branches:  trunk
changeset: 546016:91a9f1f9df20
user:      blymn <blymn%NetBSD.org@localhost>
date:      Sat Apr 19 12:52:39 2003 +0000

description:
Remove the resetting of top_row, cur_item and the pattern buffer from
post_menu so menu state is kept across upost/post actions.  This addresses
PR #21218.

diffstat:

 lib/libmenu/post.c |  11 ++---------
 1 files changed, 2 insertions(+), 9 deletions(-)

diffs (32 lines):

diff -r 5ffc20327734 -r 91a9f1f9df20 lib/libmenu/post.c
--- a/lib/libmenu/post.c        Sat Apr 19 12:33:35 2003 +0000
+++ b/lib/libmenu/post.c        Sat Apr 19 12:52:39 2003 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: post.c,v 1.11 2003/03/09 01:08:48 lukem Exp $  */
+/*     $NetBSD: post.c,v 1.12 2003/04/19 12:52:39 blymn Exp $  */
 
 /*-
  * Copyright (c) 1998-1999 Brett Lymn (blymn%baea.com.au@localhost, brett_lymn%yahoo.com.au@localhost)
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__RCSID("$NetBSD: post.c,v 1.11 2003/03/09 01:08:48 lukem Exp $");
+__RCSID("$NetBSD: post.c,v 1.12 2003/04/19 12:52:39 blymn Exp $");
 
 #include <menu.h>
 #include <stdlib.h>
@@ -54,13 +54,6 @@
                return E_NOT_CONNECTED;
 
        menu->in_init = 1;
-       menu->cur_item = 0; /* reset current item in case it was set before */
-       menu->top_row = 0; /* and the top row too */
-       if (menu->pattern != NULL) { /* and the pattern buffer....sigh */
-               free(menu->pattern);
-               menu->plen = 0;
-               menu->match_len = 0;
-       }
        
        if (menu->menu_init != NULL)
                menu->menu_init(menu);



Home | Main Index | Thread Index | Old Index