From 9b6e476a46387bae9d080f6c80a8c345831d5e76 Mon Sep 17 00:00:00 2001 From: David Lawrence Ramsey Date: Tue, 28 Sep 2004 15:58:56 +0000 Subject: [PATCH] resetstatuspos should be a bool, not an int git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1947 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- src/global.c | 2 +- src/proto.h | 2 +- src/winio.c | 14 +++++++------- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/global.c b/src/global.c index db68d0ea..e0f48012 100644 --- a/src/global.c +++ b/src/global.c @@ -93,7 +93,7 @@ size_t quotelen; /* strlen(quotestr) */ char *backup_dir = NULL; /* Backup directory. */ #endif -int resetstatuspos; /* Hack for resetting the status bar +bool resetstatuspos; /* Hack for resetting the status bar cursor position */ char *answer = NULL; /* Answer str to many questions */ int totlines = 0; /* Total number of lines in the file */ diff --git a/src/proto.h b/src/proto.h index fe046097..0b376fde 100644 --- a/src/proto.h +++ b/src/proto.h @@ -82,7 +82,7 @@ extern char *full_operating_dir; extern char *alt_speller; #endif -extern int resetstatuspos; +extern bool resetstatuspos; extern struct stat fileinfo; extern filestruct *current, *fileage, *edittop, *filebot; extern filestruct *cutbuffer; diff --git a/src/winio.c b/src/winio.c index d5c0ee3c..834f478e 100644 --- a/src/winio.c +++ b/src/winio.c @@ -3011,42 +3011,42 @@ int statusq(int allowtabs, const shortcut *s, const char *def, #endif ); free(foo); - resetstatuspos = 0; + resetstatuspos = FALSE; switch (ret) { case NANO_FIRSTLINE_KEY: case NANO_FIRSTLINE_FKEY: do_first_line(); - resetstatuspos = 1; + resetstatuspos = TRUE; break; case NANO_LASTLINE_KEY: case NANO_LASTLINE_FKEY: do_last_line(); - resetstatuspos = 1; + resetstatuspos = TRUE; break; #ifndef DISABLE_JUSTIFY case NANO_PARABEGIN_KEY: case NANO_PARABEGIN_ALTKEY1: case NANO_PARABEGIN_ALTKEY2: do_para_begin(); - resetstatuspos = 1; + resetstatuspos = TRUE; break; case NANO_PARAEND_KEY: case NANO_PARAEND_ALTKEY1: case NANO_PARAEND_ALTKEY2: do_para_end(); - resetstatuspos = 1; + resetstatuspos = TRUE; break; case NANO_FULLJUSTIFY_KEY: case NANO_FULLJUSTIFY_ALTKEY: if (!ISSET(VIEW_MODE)) do_full_justify(); - resetstatuspos = 1; + resetstatuspos = TRUE; break; #endif case NANO_CANCEL_KEY: ret = -1; - resetstatuspos = 1; + resetstatuspos = TRUE; break; } blank_statusbar(); -- 2.39.5