/[emacs]/emacs/lisp/menu-bar.el
ViewVC logotype

Diff of /emacs/lisp/menu-bar.el

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.182 by eliz, Sun Sep 23 11:57:34 2001 UTC revision 1.182.4.1 by eliz, Mon Nov 12 19:22:32 2001 UTC
# Line 398  A large number or nil slows down menu re Line 398  A large number or nil slows down menu re
398                :help "Paste (yank) text cut or copied earlier"))                :help "Paste (yank) text cut or copied earlier"))
399  (define-key menu-bar-edit-menu [paste]  (define-key menu-bar-edit-menu [paste]
400    '(menu-item "Paste" yank    '(menu-item "Paste" yank
401                :enable (and (x-selection-exists-p) (not buffer-read-only))                :enable (and
402                           ;; Emacs compiled --without-x doesn't have
403                           ;; x-selection-exists-p.
404                           (fboundp 'x-selection-exists-p)
405                           (x-selection-exists-p) (not buffer-read-only))
406                :help "Paste (yank) text most recently cut/copied"))                :help "Paste (yank) text most recently cut/copied"))
407  (define-key menu-bar-edit-menu [copy]  (define-key menu-bar-edit-menu [copy]
408    '(menu-item "Copy" menu-bar-kill-ring-save    '(menu-item "Copy" menu-bar-kill-ring-save
# Line 433  A large number or nil slows down menu re Line 437  A large number or nil slows down menu re
437  (put 'clipboard-kill-region 'menu-enable 'mark-active)  (put 'clipboard-kill-region 'menu-enable 'mark-active)
438  (put 'clipboard-kill-ring-save 'menu-enable 'mark-active)  (put 'clipboard-kill-ring-save 'menu-enable 'mark-active)
439  (put 'clipboard-yank 'menu-enable  (put 'clipboard-yank 'menu-enable
440       '(or (x-selection-exists-p) (x-selection-exists-p 'CLIPBOARD)))       '(or (and (fboundp 'x-selection-exists-p) (x-selection-exists-p))
441              (x-selection-exists-p 'CLIPBOARD)))
442    
443  (defun clipboard-yank ()  (defun clipboard-yank ()
444    "Insert the clipboard contents, or the last stretch of killed text."    "Insert the clipboard contents, or the last stretch of killed text."

Legend:
Removed from v.1.182  
changed lines
  Added in v.1.182.4.1

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26