changeset: 6305:d3096e8796e7
user:      Kevin McCarthy <[email protected]>
date:      Tue Apr 16 20:12:25 2013 -0700
link:      http://dev.mutt.org/hg/mutt/rev/d3096e8796e7

Don't exit pager if quit=ask is answered "no".

This patch addresses ticket 2788.

Currently if you quit ('Q') from inside the pager, with quit=ask-yes
or quit=ask-no, and you respond "no", mutt leaves you back in the index
menu.

This patch changes it so that mutt does not exit the pager.

diffs (19 lines):

diff -r 4c5163272b9c -r d3096e8796e7 pager.c
--- a/pager.c   Thu Apr 11 02:17:41 2013 +0000
+++ b/pager.c   Tue Apr 16 20:12:25 2013 -0700
@@ -1927,6 +1927,15 @@
        ch = -1;
        break;
 
+      case OP_QUIT:
+       if (query_quadoption (OPT_QUIT, _("Quit Mutt?")) == M_YES)
+       {
+         /* avoid prompting again in the index menu */
+         set_quadoption (OPT_QUIT, M_YES);
+         ch = -1;
+       }
+       break;
+
       case OP_NEXT_PAGE:
        if (lineInfo[curline].offset < sb.st_size-1)
        {

Reply via email to