when DISABLE_HELP is defined, leave out some unused shortcut and toggle
list parameters git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@3815 35c25a1d-7b9e-4130-9fde-d3aeb78583b8master
parent
1b4ae6997e
commit
bd28ee472b
|
@ -106,6 +106,13 @@ CVS code -
|
|||
- Don't return NULL when the current directory doesn't exist, as
|
||||
we can still recover from that. (DLR, found by Mike Frysinger)
|
||||
- Add various cleanups. (DLR)
|
||||
- global.c:
|
||||
shortcut_init(), sc_init_one()
|
||||
- Don't include blank_after when DISABLE_HELP is defined, as
|
||||
it's never used then. (DLR)
|
||||
toggle_init(), toggle_init_one()
|
||||
- Don't include desc or blank_after when DISABLE_HELP is
|
||||
defined, as neither are ever used then. (DLR)
|
||||
- help.c:
|
||||
do_help()
|
||||
- Simplify screen update handling and exiting. (DLR)
|
||||
|
|
418
src/global.c
418
src/global.c
File diff suppressed because it is too large
Load Diff
|
@ -291,11 +291,12 @@ typedef struct shortcut {
|
|||
#ifndef DISABLE_HELP
|
||||
const char *help;
|
||||
/* The help file entry text for this function. */
|
||||
#endif
|
||||
bool blank_after;
|
||||
/* Whether there should be a blank line after the help entry
|
||||
* text for this function. */
|
||||
/* Key values that aren't used should be set to NANO_NO_KEY. */
|
||||
#endif
|
||||
/* Note: Key values that aren't used should be set to
|
||||
* NANO_NO_KEY. */
|
||||
int ctrlval;
|
||||
/* The special sentinel key or control key we want bound, if
|
||||
* any. */
|
||||
|
@ -320,9 +321,11 @@ typedef struct toggle {
|
|||
const char *desc;
|
||||
/* The description of the toggle, e.g. "Cut to end"; we'll
|
||||
* append Enabled or Disabled to it. */
|
||||
#ifndef DISABLE_HELP
|
||||
bool blank_after;
|
||||
/* Whether there should be a blank line after the description of
|
||||
* the toggle. */
|
||||
#endif
|
||||
long flag;
|
||||
/* Which flag actually gets toggled. */
|
||||
struct toggle *next;
|
||||
|
|
15
src/proto.h
15
src/proto.h
|
@ -342,16 +342,19 @@ void save_history(void);
|
|||
/* Public functions in global.c. */
|
||||
size_t length_of_list(const shortcut *s);
|
||||
#ifndef NANO_TINY
|
||||
void toggle_init_one(int val, const char *desc, bool blank_after, long
|
||||
flag);
|
||||
void toggle_init_one(int val
|
||||
#ifndef DISABLE_HELP
|
||||
, const char *desc, bool blank_after
|
||||
#endif
|
||||
, long flag);
|
||||
void toggle_init(void);
|
||||
#endif
|
||||
void sc_init_one(shortcut **shortcutage, int ctrlval, const char *desc,
|
||||
void sc_init_one(shortcut **shortcutage, int ctrlval, const char *desc
|
||||
#ifndef DISABLE_HELP
|
||||
const char *help,
|
||||
, const char *help, bool blank_after
|
||||
#endif
|
||||
bool blank_after, int metaval, int funcval, int miscval, bool
|
||||
view, void (*func)(void));
|
||||
, int metaval, int funcval, int miscval, bool view, void
|
||||
(*func)(void));
|
||||
void shortcut_init(bool unjustify);
|
||||
void free_shortcutage(shortcut **shortcutage);
|
||||
#ifdef DEBUG
|
||||
|
|
Loading…
Reference in New Issue