1 Return-Path: <tomi.ollila@iki.fi>
\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 38E0B431FAF
\r
6 for <notmuch@notmuchmail.org>; Sat, 9 Aug 2014 03:11:23 -0700 (PDT)
\r
7 X-Virus-Scanned: Debian amavisd-new at olra.theworths.org
\r
11 X-Spam-Status: No, score=0 tagged_above=-999 required=5 tests=[none]
\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 SPDaDnsB7m4i for <notmuch@notmuchmail.org>;
\r
16 Sat, 9 Aug 2014 03:11:17 -0700 (PDT)
\r
17 Received: from guru.guru-group.fi (guru.guru-group.fi [46.183.73.34])
\r
18 by olra.theworths.org (Postfix) with ESMTP id A0284431FAE
\r
19 for <notmuch@notmuchmail.org>; Sat, 9 Aug 2014 03:11:17 -0700 (PDT)
\r
20 Received: from guru.guru-group.fi (localhost [IPv6:::1])
\r
21 by guru.guru-group.fi (Postfix) with ESMTP id 8C32D100051;
\r
22 Sat, 9 Aug 2014 13:11:03 +0300 (EEST)
\r
23 From: Tomi Ollila <tomi.ollila@iki.fi>
\r
24 To: Austin Clements <amdragon@MIT.EDU>, notmuch@notmuchmail.org
\r
25 Subject: Re: [PATCH v2] emacs: Improved compatibility for window-body-width
\r
27 In-Reply-To: <1407517565-24490-1-git-send-email-amdragon@mit.edu>
\r
28 References: <1407510680-17576-1-git-send-email-amdragon@mit.edu>
\r
29 <1407517565-24490-1-git-send-email-amdragon@mit.edu>
\r
30 User-Agent: Notmuch/0.18.1+25~gdaf4b6f (http://notmuchmail.org) Emacs/24.3.1
\r
31 (x86_64-unknown-linux-gnu)
\r
32 X-Face: HhBM'cA~<r"^Xv\KRN0P{vn'Y"Kd;zg_y3S[4)KSN~s?O\"QPoL
\r
33 $[Xv_BD:i/F$WiEWax}R(MPS`^UaptOGD`*/=@\1lKoVa9tnrg0TW?"r7aRtgk[F
\r
34 !)g;OY^,BjTbr)Np:%c_o'jj,Z
\r
35 Date: Sat, 09 Aug 2014 13:11:03 +0300
\r
36 Message-ID: <m2k36ic6rs.fsf@guru.guru-group.fi>
\r
38 Content-Type: text/plain
\r
39 X-BeenThere: notmuch@notmuchmail.org
\r
40 X-Mailman-Version: 2.1.13
\r
42 List-Id: "Use and development of the notmuch mail system."
\r
43 <notmuch.notmuchmail.org>
\r
44 List-Unsubscribe: <http://notmuchmail.org/mailman/options/notmuch>,
\r
45 <mailto:notmuch-request@notmuchmail.org?subject=unsubscribe>
\r
46 List-Archive: <http://notmuchmail.org/pipermail/notmuch>
\r
47 List-Post: <mailto:notmuch@notmuchmail.org>
\r
48 List-Help: <mailto:notmuch-request@notmuchmail.org?subject=help>
\r
49 List-Subscribe: <http://notmuchmail.org/mailman/listinfo/notmuch>,
\r
50 <mailto:notmuch-request@notmuchmail.org?subject=subscribe>
\r
51 X-List-Received-Date: Sat, 09 Aug 2014 10:11:23 -0000
\r
53 On Fri, Aug 08 2014, Austin Clements <amdragon@MIT.EDU> wrote:
\r
55 > Fix byte compiler warning "Warning: the function `window-body-width'
\r
56 > is not known to be defined." by moving our compatibility wrapper
\r
57 > before its use and simplify the definition to a defalias for the old
\r
58 > name of the function.
\r
61 > Tomi pointed out that window-body-width simply used to be called
\r
62 > window-width, so this simplifies the wrapper to a defalias.
\r
64 LGTM. Tested w/ (notmuch-jump nil "foo") in emacs 23.1.1 -- call failed
\r
65 but after calling (window-body-width).
\r
71 > emacs/notmuch-jump.el | 10 ++++------
\r
72 > 1 file changed, 4 insertions(+), 6 deletions(-)
\r
74 > diff --git a/emacs/notmuch-jump.el b/emacs/notmuch-jump.el
\r
75 > index 05bbce5..5eb0949 100644
\r
76 > --- a/emacs/notmuch-jump.el
\r
77 > +++ b/emacs/notmuch-jump.el
\r
78 > @@ -25,6 +25,10 @@
\r
79 > (require 'notmuch-lib)
\r
80 > (require 'notmuch-hello)
\r
82 > +(unless (fboundp 'window-body-width)
\r
83 > + ;; Compatibility for Emacs pre-24
\r
84 > + (defalias 'window-body-width 'window-width))
\r
87 > (defun notmuch-jump-search ()
\r
88 > "Jump to a saved search by shortcut key.
\r
89 > @@ -165,9 +169,3 @@ (defun notmuch-jump--make-keymap (action-map)
\r
90 > (setq notmuch-jump--action ',(third action))
\r
91 > (exit-minibuffer))))
\r
94 > -(unless (fboundp 'window-body-width)
\r
95 > - ;; Compatibility for Emacs pre-24
\r
96 > - (defun window-body-width (&optional window)
\r
97 > - (let ((edges (window-inside-edges window)))
\r
98 > - (- (caddr edges) (car edges)))))
\r
102 > _______________________________________________
\r
103 > notmuch mailing list
\r
104 > notmuch@notmuchmail.org
\r
105 > http://notmuchmail.org/mailman/listinfo/notmuch
\r