[PATCH 4/4] Update NEWS for user.other_name
[notmuch-archives.git] / 65 / 245d1552bd807fa4e91c74b31682e4a030cf84
1 Return-Path: <dme@dme.org>\r
2 X-Original-To: notmuch@notmuchmail.org\r
3 Delivered-To: notmuch@notmuchmail.org\r
4 Received: from localhost (localhost [127.0.0.1])\r
5         by olra.theworths.org (Postfix) with ESMTP id D1762431FAF\r
6         for <notmuch@notmuchmail.org>; Thu, 19 Jan 2012 01:34:13 -0800 (PST)\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org\r
8 X-Spam-Flag: NO\r
9 X-Spam-Score: -0.7\r
10 X-Spam-Level: \r
11 X-Spam-Status: No, score=-0.7 tagged_above=-999 required=5\r
12         tests=[RCVD_IN_DNSWL_LOW=-0.7] autolearn=disabled\r
13 Received: from olra.theworths.org ([127.0.0.1])\r
14         by localhost (olra.theworths.org [127.0.0.1]) (amavisd-new, port 10024)\r
15         with ESMTP id fFADe6XP9Qdl for <notmuch@notmuchmail.org>;\r
16         Thu, 19 Jan 2012 01:34:13 -0800 (PST)\r
17 Received: from mail-ww0-f45.google.com (mail-ww0-f45.google.com\r
18  [74.125.82.45])        (using TLSv1 with cipher RC4-SHA (128/128 bits))        (No client\r
19  certificate requested) by olra.theworths.org (Postfix) with ESMTPS id\r
20  0823A431FAE    for <notmuch@notmuchmail.org>; Thu, 19 Jan 2012 01:34:12 -0800\r
21  (PST)\r
22 Received: by wgbdt12 with SMTP id dt12so683906wgb.2\r
23         for <notmuch@notmuchmail.org>; Thu, 19 Jan 2012 01:34:11 -0800 (PST)\r
24 Received: by 10.180.102.169 with SMTP id fp9mr42514701wib.9.1326965651902;\r
25         Thu, 19 Jan 2012 01:34:11 -0800 (PST)\r
26 Received: from hotblack-desiato.hh.sledj.net\r
27         (host81-149-164-25.in-addr.btopenworld.com. [81.149.164.25])\r
28         by mx.google.com with ESMTPS id eb2sm27042459wib.0.2012.01.19.01.34.10\r
29         (version=TLSv1/SSLv3 cipher=OTHER);\r
30         Thu, 19 Jan 2012 01:34:11 -0800 (PST)\r
31 Received: by hotblack-desiato.hh.sledj.net (Postfix, from userid 30000)\r
32         id CFC9C9FE3F; Thu, 19 Jan 2012 09:34:08 +0000 (GMT)\r
33 From: David Edmondson <dme@dme.org>\r
34 To: notmuch@notmuchmail.org\r
35 Subject: [PATCH] emacs: Make the part content available to `mm-inlinable-p'.\r
36 Date: Thu, 19 Jan 2012 09:34:07 +0000\r
37 Message-Id: <1326965647-1222-1-git-send-email-dme@dme.org>\r
38 X-Mailer: git-send-email 1.7.8.3\r
39 In-Reply-To: <87k44o6o6e.fsf@gmail.com>\r
40 References: <87k44o6o6e.fsf@gmail.com>\r
41 X-BeenThere: notmuch@notmuchmail.org\r
42 X-Mailman-Version: 2.1.13\r
43 Precedence: list\r
44 List-Id: "Use and development of the notmuch mail system."\r
45         <notmuch.notmuchmail.org>\r
46 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,\r
47         <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>\r
48 List-Archive: <http://notmuchmail.org/pipermail/notmuch>\r
49 List-Post: <mailto:notmuch@notmuchmail.org>\r
50 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>\r
51 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,\r
52         <mailto:notmuch-request@notmuchmail.org?subject=subscribe>\r
53 X-List-Received-Date: Thu, 19 Jan 2012 09:34:14 -0000\r
54 \r
55 The `mm-inlinable-p' function works better if it has access to the\r
56 data of the relevant part, so load that content before calling it.\r
57 \r
58 Don't load the content for parts that the user has indicated no desire\r
59 to inline.\r
60 \r
61 This fixes the display of attached image/jpeg parts, for example.\r
62 ---\r
63 \r
64 Updated as described in id:"cunboq06szv.fsf@hotblack-desiato.hh.sledj.net".\r
65 \r
66  emacs/notmuch-show.el |   17 +++++++++--------\r
67  1 files changed, 9 insertions(+), 8 deletions(-)\r
68 \r
69 diff --git a/emacs/notmuch-show.el b/emacs/notmuch-show.el\r
70 index 2df8d3b..7e9c9b4 100644\r
71 --- a/emacs/notmuch-show.el\r
72 +++ b/emacs/notmuch-show.el\r
73 @@ -330,14 +330,15 @@ current buffer, if possible."\r
74      (with-temp-buffer\r
75        (let* ((charset (plist-get part :content-charset))\r
76              (handle (mm-make-handle (current-buffer) `(,content-type (charset . ,charset)))))\r
77 -       (if (and (mm-inlinable-p handle)\r
78 -                (mm-inlined-p handle))\r
79 -           (let ((content (notmuch-show-get-bodypart-content msg part nth)))\r
80 -             (insert content)\r
81 -             (set-buffer display-buffer)\r
82 -             (mm-display-part handle)\r
83 -             t)\r
84 -         nil)))))\r
85 +       ;; If the user wants the part inlined, insert the content and\r
86 +       ;; test whether we are able to inline it (which includes both\r
87 +       ;; capability and suitability tests).\r
88 +       (when (mm-inlined-p handle)\r
89 +         (insert (notmuch-show-get-bodypart-content msg part nth))\r
90 +         (when (mm-inlinable-p handle)\r
91 +           (set-buffer display-buffer)\r
92 +           (mm-display-part handle)\r
93 +           t))))))\r
94  \r
95  (defvar notmuch-show-multipart/alternative-discouraged\r
96    '(\r
97 -- \r
98 1.7.8.3\r
99 \r