don't rely on the return value of curs_set(), as it's broken on e.g.
slang; instead, explicitly turn the cursor off where we need to git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@1798 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
Этот коммит содержится в:
родитель
e7638ea75f
Коммит
ae064bf255
@ -371,7 +371,10 @@ CVS code -
|
||||
do_help()
|
||||
- Overhaul for efficiency, and allow scrolling through the help
|
||||
via the arrow keys as well as the paging keys. (David
|
||||
Benbennick)
|
||||
Benbennick) DLR: Revert the use of the return value of
|
||||
curs_set() to restore the previous state of the cursor, as
|
||||
some curses implementations (including slang) get it wrong,
|
||||
and explicitly turn the cursor off where needed instead.
|
||||
do_credits()
|
||||
- Use napms() instead of nanosleep(), as it does the same thing
|
||||
(aside from taking an argument in milliseconds instead of
|
||||
|
@ -2683,6 +2683,7 @@ char *do_browser(const char *inpath)
|
||||
case NANO_HELP_FKEY:
|
||||
case '?': /* Pico compatibility */
|
||||
do_help();
|
||||
curs_set(0);
|
||||
break;
|
||||
case NANO_ENTER_KEY:
|
||||
case 'S': /* Pico compatibility */
|
||||
|
@ -3022,13 +3022,13 @@ int do_help(void)
|
||||
int kbinput = ERR, meta_key;
|
||||
|
||||
int old_no_help = ISSET(NO_HELP);
|
||||
int old_cursor = curs_set(0);
|
||||
#ifndef DISABLE_MOUSE
|
||||
const shortcut *oldshortcut = currshortcut;
|
||||
/* We will set currshortcut to allow clicking on the help
|
||||
screen shortcut list. */
|
||||
#endif
|
||||
|
||||
curs_set(0);
|
||||
blank_edit();
|
||||
wattroff(bottomwin, A_REVERSE);
|
||||
blank_statusbar();
|
||||
@ -3127,7 +3127,7 @@ int do_help(void)
|
||||
} else
|
||||
bottombars(currshortcut);
|
||||
|
||||
curs_set(old_cursor);
|
||||
curs_set(1);
|
||||
edit_refresh();
|
||||
|
||||
/* The help_init() at the beginning allocated help_text, which has
|
||||
|
Загрузка…
x
Ссылка в новой задаче
Block a user