/[LeafOK_CVS]/lbbs/src/menu_proc.c
ViewVC logotype

Diff of /lbbs/src/menu_proc.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1.41 by sysadm, Sat Oct 18 12:06:10 2025 UTC Revision 1.47 by sysadm, Wed Nov 5 14:59:31 2025 UTC
# Line 1  Line 1 
1  /***************************************************************************  /* SPDX-License-Identifier: GPL-3.0-or-later */
2                                                    menu_proc.c  -  description  /*
3                                                           -------------------   * menu_proc
4          Copyright            : (C) 2004-2025 by Leaflet   *   - handler functions of menu commands
5          Email                : leaflet@leafok.com   *
6   ***************************************************************************/   * Copyright (C) 2004-2025  Leaflet <leaflet@leafok.com>
7     */
 /***************************************************************************  
  *                                                                         *  
  *   This program is free software; you can redistribute it and/or modify  *  
  *   it under the terms of the GNU General Public License as published by  *  
  *   the Free Software Foundation; either version 3 of the License, or     *  
  *   (at your option) any later version.                                   *  
  *                                                                         *  
  ***************************************************************************/  
8    
9  #include "article_cache.h"  #include "article_cache.h"
10  #include "article_favor_display.h"  #include "article_favor_display.h"
# Line 26  Line 18 
18  #include "menu.h"  #include "menu.h"
19  #include "section_list_display.h"  #include "section_list_display.h"
20  #include "screen.h"  #include "screen.h"
21    #include "user_info_update.h"
22    #include "user_list_display.h"
23  #include "user_priv.h"  #include "user_priv.h"
24  #include <dlfcn.h>  #include <dlfcn.h>
25  #include <errno.h>  #include <errno.h>
# Line 43  int list_section(void *param) Line 37  int list_section(void *param)
37          return REDRAW;          return REDRAW;
38  }  }
39    
40  typedef union exec_handler_t{  typedef union exec_handler_t
41    {
42          void *p;          void *p;
43          int (*handler)();          int (*handler)();
44  } exec_handler;  } exec_handler;
# Line 275  int show_top10_menu(void *param) Line 270  int show_top10_menu(void *param)
270                                  show_top10 = 0;                                  show_top10 = 0;
271                                  return 0;                                  return 0;
272                          case KEY_TIMEOUT:                          case KEY_TIMEOUT:
273                                  if (time(NULL) - BBS_last_access_tm >= MAX_DELAY_TIME)                                  if (time(NULL) - BBS_last_access_tm >= BBS_max_user_idle_time)
274                                  {                                  {
275                                          log_error("User input timeout\n");                                          log_error("User input timeout\n");
276                                          show_top10 = 0;                                          show_top10 = 0;
# Line 342  int favor_topic(void *param) Line 337  int favor_topic(void *param)
337          }          }
338    
339          return REDRAW;          return REDRAW;
340    }
341    
342    int list_user(void *param)
343    {
344            if (user_list_display(0) < 0)
345            {
346                    log_error("user_list_display(all_user) error\n");
347            }
348    
349            return REDRAW;
350    }
351    
352    int list_online_user(void *param)
353    {
354            if (user_list_display(1) < 0)
355            {
356                    log_error("user_list_display(online_user) error\n");
357            }
358    
359            return REDRAW;
360    }
361    
362    int edit_intro(void *param)
363    {
364            if (user_intro_edit(BBS_priv.uid) < 0)
365            {
366                    log_error("user_intro_edit(%d) error\n", BBS_priv.uid);
367            }
368    
369            return REDRAW;
370  }  }


Legend:
Removed lines/characters  
Changed lines/characters
  Added lines/characters

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1