Fixed a bug in page_down() and moved page_up() to move.c where it belongs

git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@62 35c25a1d-7b9e-4130-9fde-d3aeb78583b8
master
Chris Allegretta 2000-07-03 04:24:39 +00:00
parent 67105eb11f
commit 1e57e68e57
5 changed files with 47 additions and 40 deletions

View File

@ -7,10 +7,16 @@ CVS code changes since last release -
do_search() in search.c, globals in nano.h and do_search() in search.c, globals in nano.h and
shortcut_init() in global.c. shortcut_init() in global.c.
- changed 'sprintf' calls to safer 'snprintf' - changed 'sprintf' calls to safer 'snprintf'
- move.c:
page_down():
- Fixed a bug that caused nano to not update when
current->next == NULL (e.g. paging down to the very bottom of
ABOUT NLS wouldn't work).
- nano.c: - nano.c:
- Removed dual alt_speller variables, oops! (Rocco Corsi) - Removed dual alt_speller variables, oops! (Rocco Corsi)
- Removed unnecessary do_oldspell function (Rocco Corsi). Added - Removed unnecessary do_oldspell function (Rocco Corsi). Added
SMALL_NANO #ifdef around actual spell function. SMALL_NANO #ifdef around actual spell function.
- Moved page_up() to move.c where is belongs.
- de.po: - de.po:
- Revised translations by floki@bigfoot.com. - Revised translations by floki@bigfoot.com.
- fi.po: - fi.po:

19
move.c
View File

@ -134,6 +134,25 @@ void page_up_center(void)
} }
int page_up(void)
{
wrap_reset();
current_x = 0;
placewewant = 0;
if (current == fileage)
return 0;
current_y = 0;
edit_update_bot(edittop);
update_cursor();
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
int do_up(void) int do_up(void)
{ {
wrap_reset(); wrap_reset();

18
nano.c
View File

@ -886,24 +886,6 @@ void do_early_abort(void)
blank_statusbar_refresh(); blank_statusbar_refresh();
} }
int page_up(void)
{
wrap_reset();
current_x = 0;
placewewant = 0;
if (current == fileage)
return 0;
current_y = 0;
edit_update_bot(edittop);
update_cursor();
UNSET(KEEP_CUTBUFFER);
check_statblank();
return 1;
}
void delete_buffer(filestruct * inptr) void delete_buffer(filestruct * inptr)
{ {
if (inptr != NULL) { if (inptr != NULL) {

View File

@ -6,7 +6,7 @@
msgid "" msgid ""
msgstr "" msgstr ""
"Project-Id-Version: PACKAGE VERSION\n" "Project-Id-Version: PACKAGE VERSION\n"
"POT-Creation-Date: 2000-07-02 23:21-0400\n" "POT-Creation-Date: 2000-07-03 00:27-0400\n"
"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n" "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n" "Language-Team: LANGUAGE <LL@li.org>\n"
@ -55,7 +55,7 @@ msgstr ""
msgid "File to insert [from ./] " msgid "File to insert [from ./] "
msgstr "" msgstr ""
#: files.c:270 files.c:294 files.c:458 nano.c:1123 #: files.c:270 files.c:294 files.c:458 nano.c:1105
msgid "Cancelled" msgid "Cancelled"
msgstr "" msgstr ""
@ -560,85 +560,85 @@ msgstr ""
msgid "check_wrap called with inptr->data=\"%s\"\n" msgid "check_wrap called with inptr->data=\"%s\"\n"
msgstr "" msgstr ""
#: nano.c:925 #: nano.c:907
#, c-format #, c-format
msgid "current->data now = \"%s\"\n" msgid "current->data now = \"%s\"\n"
msgstr "" msgstr ""
#: nano.c:969 #: nano.c:951
#, c-format #, c-format
msgid "After, data = \"%s\"\n" msgid "After, data = \"%s\"\n"
msgstr "" msgstr ""
#: nano.c:1032 #: nano.c:1014
msgid "Error deleting tempfile, ack!" msgid "Error deleting tempfile, ack!"
msgstr "" msgstr ""
#: nano.c:1050 #: nano.c:1032
#, c-format #, c-format
msgid "Could not create a temporary filename: %s" msgid "Could not create a temporary filename: %s"
msgstr "" msgstr ""
#: nano.c:1074 #: nano.c:1056
#, c-format #, c-format
msgid "Could not invoke spell program \"%s\"" msgid "Could not invoke spell program \"%s\""
msgstr "" msgstr ""
#. Why 32512? I dont know! #. Why 32512? I dont know!
#: nano.c:1080 #: nano.c:1062
msgid "Could not invoke \"ispell\"" msgid "Could not invoke \"ispell\""
msgstr "" msgstr ""
#: nano.c:1092 #: nano.c:1074
msgid "Finished checking spelling" msgid "Finished checking spelling"
msgstr "" msgstr ""
#: nano.c:1110 #: nano.c:1092
msgid "Save modified buffer (ANSWERING \"No\" WILL DESTROY CHANGES) ? " msgid "Save modified buffer (ANSWERING \"No\" WILL DESTROY CHANGES) ? "
msgstr "" msgstr ""
#: nano.c:1233 #: nano.c:1215
msgid "Cannot resize top win" msgid "Cannot resize top win"
msgstr "" msgstr ""
#: nano.c:1235 #: nano.c:1217
msgid "Cannot move top win" msgid "Cannot move top win"
msgstr "" msgstr ""
#: nano.c:1237 #: nano.c:1219
msgid "Cannot resize edit win" msgid "Cannot resize edit win"
msgstr "" msgstr ""
#: nano.c:1239 #: nano.c:1221
msgid "Cannot move edit win" msgid "Cannot move edit win"
msgstr "" msgstr ""
#: nano.c:1241 #: nano.c:1223
msgid "Cannot resize bottom win" msgid "Cannot resize bottom win"
msgstr "" msgstr ""
#: nano.c:1243 #: nano.c:1225
msgid "Cannot move bottom win" msgid "Cannot move bottom win"
msgstr "" msgstr ""
#: nano.c:1707 #: nano.c:1689
msgid "Main: set up windows\n" msgid "Main: set up windows\n"
msgstr "" msgstr ""
#: nano.c:1729 #: nano.c:1711
msgid "Main: bottom win\n" msgid "Main: bottom win\n"
msgstr "" msgstr ""
#: nano.c:1735 #: nano.c:1717
msgid "Main: open file\n" msgid "Main: open file\n"
msgstr "" msgstr ""
#: nano.c:1808 #: nano.c:1790
#, c-format #, c-format
msgid "I got Alt-[-%c! (%d)\n" msgid "I got Alt-[-%c! (%d)\n"
msgstr "" msgstr ""
#: nano.c:1824 #: nano.c:1806
#, c-format #, c-format
msgid "I got Alt-%c! (%d)\n" msgid "I got Alt-%c! (%d)\n"
msgstr "" msgstr ""

View File

@ -850,7 +850,7 @@ void edit_update_top(filestruct * fileptr)
int i; int i;
filestruct *temp = fileptr; filestruct *temp = fileptr;
if (fileptr->next == NULL || fileptr == NULL) if (fileptr == NULL)
return; return;
i = 0; i = 0;