diff options
author | Miles Bader <[email protected]> | 2007-06-06 02:19:13 +0000 |
---|---|---|
committer | Miles Bader <[email protected]> | 2007-06-06 02:19:13 +0000 |
commit | 29ec0239fd440dcc19b216fc63efdf3b050793d4 (patch) | |
tree | 8ba27bd0992d47fefdbd54e687b6ec11005c46e9 /lisp | |
parent | 3a1c1b157102420cd871e9c9ada10d17fa0b4589 (diff) |
Merge from gnus--rel--5.10
Patches applied:
* gnus--rel--5.10 (patch 226)
- Update from CVS
2007-06-04 Katsumi Yamaoka <[email protected]>
* lisp/gnus/gnus-art.el (gnus-mime-view-part-externally)
(gnus-mime-view-part-internally): Fix predicate function passed to
completing-read.
* lisp/gnus/mm-decode.el (mm-image-fit-p): Return t if argument is
not an image; return t if image size is just the same as window size.
Revision: [email protected]/emacs--devo--0--patch-786
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/gnus/ChangeLog | 9 | ||||
-rw-r--r-- | lisp/gnus/gnus-art.el | 4 | ||||
-rw-r--r-- | lisp/gnus/mm-decode.el | 25 |
3 files changed, 24 insertions, 14 deletions
diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 631869e4f3..93c860812c 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,12 @@ +2007-06-04 Katsumi Yamaoka <[email protected]> + + * gnus-art.el (gnus-mime-view-part-externally) + (gnus-mime-view-part-internally): Fix predicate function passed to + completing-read. + + * mm-decode.el (mm-image-fit-p): Return t if argument is not an image; + return t if image size is just the same as window size. + 2007-05-28 Katsumi Yamaoka <[email protected]> * message.el (message-pop-to-buffer): Add switch-function argument. diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index 013bf48110..24273abb37 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el @@ -4674,7 +4674,7 @@ specified charset." (mm-enable-external t)) (if (not (stringp method)) (gnus-mime-view-part-as-type - nil (lambda (type) (stringp (mailcap-mime-info type)))) + nil (lambda (types) (stringp (mailcap-mime-info (car types))))) (when handle (if (mm-handle-undisplayer handle) (mm-remove-part handle) @@ -4695,7 +4695,7 @@ If no internal viewer is available, use an external viewer." (inhibit-read-only t)) (if (not (mm-inlinable-p handle)) (gnus-mime-view-part-as-type - nil (lambda (type) (mm-inlinable-p handle type))) + nil (lambda (types) (mm-inlinable-p handle (car types)))) (when handle (if (mm-handle-undisplayer handle) (mm-remove-part handle) diff --git a/lisp/gnus/mm-decode.el b/lisp/gnus/mm-decode.el index 6d52d8b2f1..028855ab34 100644 --- a/lisp/gnus/mm-decode.el +++ b/lisp/gnus/mm-decode.el @@ -1371,18 +1371,19 @@ be determined." (defun mm-image-fit-p (handle) "Say whether the image in HANDLE will fit the current window." (let ((image (mm-get-image handle))) - (if (fboundp 'glyph-width) - ;; XEmacs' glyphs can actually tell us about their width, so - ;; lets be nice and smart about them. - (or mm-inline-large-images - (and (< (glyph-width image) (window-pixel-width)) - (< (glyph-height image) (window-pixel-height)))) - (let* ((size (image-size image)) - (w (car size)) - (h (cdr size))) - (or mm-inline-large-images - (and (< h (1- (window-height))) ; Don't include mode line. - (< w (window-width)))))))) + (or (not image) + (if (fboundp 'glyph-width) + ;; XEmacs' glyphs can actually tell us about their width, so + ;; lets be nice and smart about them. + (or mm-inline-large-images + (and (<= (glyph-width image) (window-pixel-width)) + (<= (glyph-height image) (window-pixel-height)))) + (let* ((size (image-size image)) + (w (car size)) + (h (cdr size))) + (or mm-inline-large-images + (and (<= h (1- (window-height))) ; Don't include mode line. + (<= w (window-width))))))))) (defun mm-valid-image-format-p (format) "Say whether FORMAT can be displayed natively by Emacs." |