bindings: move the noconvert toggle from the main to the insert menu

Also add feedback, so that it will be clear whether a file will be
inserted unconverted or not.

This addresses https://savannah.gnu.org/bugs/?54536.
This commit is contained in:
Benno Schulenberg
2018-08-19 12:35:15 +02:00
parent 8d6b205e4c
commit 6d62682ddb
3 changed files with 27 additions and 7 deletions

View File

@@ -1093,10 +1093,20 @@ void do_insertfile(void)
{
#ifdef ENABLE_MULTIBUFFER
if (ISSET(MULTIBUFFER))
msg = _("File to insert into new buffer [from %s]");
#ifndef NANO_TINY
if ISSET(NO_CONVERT)
msg = _("File to read unconverted into new buffer [from %s]");
else
#endif
msg = _("File to read into new buffer [from %s]");
else
#endif
msg = _("File to insert [from %s]");
#ifndef NANO_TINY
if ISSET(NO_CONVERT)
msg = _("File to insert unconverted [from %s]");
else
#endif
msg = _("File to insert [from %s]");
}
present_path = mallocstrcpy(present_path, "./");
@@ -1139,6 +1149,10 @@ void do_insertfile(void)
}
#endif
#ifndef NANO_TINY
if (func == flip_convert) {
TOGGLE(NO_CONVERT);
continue;
}
if (func == flip_execute) {
execute = !execute;
continue;