* src/color.c (set_colorpairs): Improve comments and rename vars.
* src/files.c (read_line): Chop a superfluous bool -- 'prevnode' being
NULL is enough indication that the first line is being read.
+ * src/files.c (switch_to_prevnext_buffer): Tweak comment and var name.
2015-12-11 Benno Schulenberg <bensberg@justemail.net>
* doc/syntax/Makefile.am: Add missing autoconf and nftables syntaxes.
}
#ifndef DISABLE_MULTIBUFFER
-/* Switch to the next file buffer if next_buf is TRUE. Otherwise,
- * switch to the previous file buffer. */
-void switch_to_prevnext_buffer(bool next_buf, bool quiet)
+/* Switch to a neighbouring file buffer; to the next if to_next is TRUE;
+ * otherwise, to the previous one. */
+void switch_to_prevnext_buffer(bool to_next, bool quiet)
{
assert(openfile != NULL);
- /* If only one file buffer is open, indicate it on the statusbar and
- * get out. */
+ /* If only one file buffer is open, say so and get out. */
if (openfile == openfile->next) {
- if (quiet == FALSE)
+ if (!quiet)
statusbar(_("No more open file buffers"));
return;
}
- /* Switch to the next or previous file buffer, depending on the
- * value of next_buf. */
- openfile = next_buf ? openfile->next : openfile->prev;
+ /* Switch to the next or previous file buffer. */
+ openfile = to_next ? openfile->next : openfile->prev;
#ifdef DEBUG
fprintf(stderr, "filename is %s\n", openfile->filename);
display_buffer();
/* Indicate the switch on the statusbar. */
- if (quiet == FALSE)
+ if (!quiet)
statusbar(_("Switched to %s"),
((openfile->filename[0] == '\0') ?
_("New Buffer") : openfile->filename));