From d8338794e7ced36f47e50a5877b4e716ccbf1060 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Fri, 10 Jun 2005 05:41:46 +0000 Subject: [PATCH] (x-clipboard-yank): Remove condition-case wrapping. --- lisp/ChangeLog | 10 ++++++++++ lisp/term/x-win.el | 10 ++++++---- 2 files changed, 16 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e3d6cdc98d6..a6f7849346b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2005-06-10 Kenichi Handa + + * term/x-win.el (x-clipboard-yank): Remove condition-case + wrapping. + +2005-06-11 Kenichi Handa + + * add-log.el (change-log-font-lock-keywords): Make the regexp for + date lines stricter. + 2005-06-10 Zhang Wei (tiny change) * term/x-win.el (x-clipboard-yank): Use x-selection-value instead diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el index a4118029eaa..458cff0ae6d 100644 --- a/lisp/term/x-win.el +++ b/lisp/term/x-win.el @@ -2183,6 +2183,11 @@ order until succeed.") ctext utf8))))) +;; Get a selection value of type TYPE by calling x-get-selection with +;; an appropiate DATA-TYPE argument decidd by `x-select-request-type'. +;; The return value is already decoded. If x-get-selection causes an +;; error, this function return nil. + (defun x-selection-value (type) (let (text) (cond ((null x-select-request-type) @@ -2465,10 +2470,7 @@ order until succeed.") (defun x-clipboard-yank () "Insert the clipboard contents, or the last stretch of killed text." (interactive) - (let ((clipboard-text - (condition-case nil - (x-selection-value 'CLIPBOARD) - (error nil))) + (let ((clipboard-text (x-selection-value 'CLIPBOARD)) (x-select-enable-clipboard t)) (if (and clipboard-text (> (length clipboard-text) 0)) (kill-new clipboard-text)) -- 2.39.5