Mercurial > emacs
comparison lisp/term/mac-win.el @ 72536:59670fc88353
(mac-apple-event-map): Rename hicommand to hi-command.
(mac-dnd-drop-data): Apply 2006-08-22 change for x-dnd-drop-data.
(special-event-map): Apply 2006-08-16 change for x-win.el.
author | YAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp> |
---|---|
date | Sun, 27 Aug 2006 07:08:07 +0000 |
parents | fd5f866a10be |
children | b09e6c8f23d4 694bbb62a75d 6823a91487f2 |
comparison
equal
deleted
inserted
replaced
72535:e7ed98d0f919 | 72536:59670fc88353 |
---|---|
1537 (put 'application-died 'mac-apple-event-id "obit") ; kAEApplicationDied | 1537 (put 'application-died 'mac-apple-event-id "obit") ; kAEApplicationDied |
1538 (put 'show-preferences 'mac-apple-event-id "pref") ; kAEShowPreferences | 1538 (put 'show-preferences 'mac-apple-event-id "pref") ; kAEShowPreferences |
1539 (put 'autosave-now 'mac-apple-event-id "asav") ; kAEAutosaveNow | 1539 (put 'autosave-now 'mac-apple-event-id "asav") ; kAEAutosaveNow |
1540 ;; kAEInternetEventClass | 1540 ;; kAEInternetEventClass |
1541 (put 'get-url 'mac-apple-event-id "GURL") ; kAEGetURL | 1541 (put 'get-url 'mac-apple-event-id "GURL") ; kAEGetURL |
1542 ;; Converted HICommand events | 1542 ;; Converted HI command events |
1543 (put 'about 'mac-apple-event-id "abou") ; kHICommandAbout | 1543 (put 'about 'mac-apple-event-id "abou") ; kHICommandAbout |
1544 | 1544 |
1545 (defmacro mac-event-spec (event) | 1545 (defmacro mac-event-spec (event) |
1546 `(nth 1 ,event)) | 1546 `(nth 1 ,event)) |
1547 | 1547 |
1737 (define-key mac-apple-event-map [core-event quit-application] | 1737 (define-key mac-apple-event-map [core-event quit-application] |
1738 'save-buffers-kill-emacs) | 1738 'save-buffers-kill-emacs) |
1739 | 1739 |
1740 (define-key mac-apple-event-map [internet-event get-url] 'mac-ae-get-url) | 1740 (define-key mac-apple-event-map [internet-event get-url] 'mac-ae-get-url) |
1741 | 1741 |
1742 (define-key mac-apple-event-map [hicommand about] 'display-splash-screen) | 1742 (define-key mac-apple-event-map [hi-command about] 'display-splash-screen) |
1743 | 1743 |
1744 ;;; Converted Carbon Events | 1744 ;;; Converted Carbon Events |
1745 (defun mac-handle-toolbar-switch-mode (event) | 1745 (defun mac-handle-toolbar-switch-mode (event) |
1746 "Toggle visibility of tool-bars in response to EVENT. | 1746 "Toggle visibility of tool-bars in response to EVENT. |
1747 With no keyboard modifiers, it toggles the visibility of the | 1747 With no keyboard modifiers, it toggles the visibility of the |
2206 (not (window-minibuffer-p w)) | 2206 (not (window-minibuffer-p w)) |
2207 (not (window-dedicated-p w))) | 2207 (not (window-dedicated-p w))) |
2208 ;; If dropping in an ordinary window which we could use, | 2208 ;; If dropping in an ordinary window which we could use, |
2209 ;; let dnd-open-file-other-window specify what to do. | 2209 ;; let dnd-open-file-other-window specify what to do. |
2210 (progn | 2210 (progn |
2211 (goto-char (posn-point (event-start event))) | 2211 (when (not mouse-yank-at-point) |
2212 (goto-char (posn-point (event-start event)))) | |
2212 (funcall handler window action data)) | 2213 (funcall handler window action data)) |
2213 ;; If we can't display the file here, | 2214 ;; If we can't display the file here, |
2214 ;; make a new window for it. | 2215 ;; make a new window for it. |
2215 (let ((dnd-open-file-other-window t)) | 2216 (let ((dnd-open-file-other-window t)) |
2216 (select-frame frame) | 2217 (select-frame frame) |
2559 ;; Enable CLIPBOARD copy/paste through menu bar commands. | 2560 ;; Enable CLIPBOARD copy/paste through menu bar commands. |
2560 (menu-bar-enable-clipboard) | 2561 (menu-bar-enable-clipboard) |
2561 | 2562 |
2562 ;; Initiate drag and drop | 2563 ;; Initiate drag and drop |
2563 | 2564 |
2564 (global-set-key [drag-n-drop] 'mac-dnd-handle-drag-n-drop-event) | 2565 (define-key special-event-map [drag-n-drop] 'mac-dnd-handle-drag-n-drop-event) |
2565 (global-set-key [M-drag-n-drop] 'mac-dnd-handle-drag-n-drop-event) | 2566 (define-key special-event-map [M-drag-n-drop] 'mac-dnd-handle-drag-n-drop-event) |
2566 | 2567 |
2567 | 2568 |
2568 ;;;; Non-toolkit Scroll bars | 2569 ;;;; Non-toolkit Scroll bars |
2569 | 2570 |
2570 (unless x-toolkit-scroll-bars | 2571 (unless x-toolkit-scroll-bars |