Commit 5f30349b authored by Glenn Morris's avatar Glenn Morris

* mouse.el (mouse-yank-primary): Reorder to silence --without-x compilation.

parent 4bd4c0af
2013-09-18 Glenn Morris <rgm@gnu.org>
* mouse.el (mouse-yank-primary):
Reorder to silence --without-x compilation.
* mail/rmailmm.el (rmail-mime-set-bulk-data):
Silence --without-x compilation.
......
......@@ -1147,22 +1147,21 @@ regardless of where you click."
(deactivate-mark)))
(or mouse-yank-at-point (mouse-set-point click))
(let ((primary
(cond
((eq (framep (selected-frame)) 'w32)
;; MS-Windows emulates PRIMARY in x-get-selection, but not
;; in x-get-selection-value (the latter only accesses the
;; clipboard). So try PRIMARY first, in case they selected
;; something with the mouse in the current Emacs session.
(or (x-get-selection 'PRIMARY)
(x-get-selection-value)))
((fboundp 'x-get-selection-value) ; MS-DOS and X.
;; On X, x-get-selection-value supports more formats and
;; encodings, so use it in preference to x-get-selection.
(or (x-get-selection-value)
(x-get-selection 'PRIMARY)))
;; FIXME: What about xterm-mouse-mode etc.?
(t
(x-get-selection 'PRIMARY)))))
(if (fboundp 'x-get-selection-value)
(if (eq (framep (selected-frame)) 'w32)
;; MS-Windows emulates PRIMARY in x-get-selection, but not
;; in x-get-selection-value (the latter only accesses the
;; clipboard). So try PRIMARY first, in case they selected
;; something with the mouse in the current Emacs session.
(or (x-get-selection 'PRIMARY)
(x-get-selection-value))
;; Else MS-DOS or X.
;; On X, x-get-selection-value supports more formats and
;; encodings, so use it in preference to x-get-selection.
(or (x-get-selection-value)
(x-get-selection 'PRIMARY)))
;; FIXME: What about xterm-mouse-mode etc.?
(x-get-selection 'PRIMARY))))
(unless primary
(error "No selection is available"))
(push-mark (point))
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment