diff options
| author | YAMAMOTO Mitsuharu | 2006-05-10 08:22:39 +0000 |
|---|---|---|
| committer | YAMAMOTO Mitsuharu | 2006-05-10 08:22:39 +0000 |
| commit | b905e809274d552c97269a1ac0ace60b0c538476 (patch) | |
| tree | fd6b83c5794d0254c6359b781b66143effc27a07 | |
| parent | 2c246c9f1af883fff191984e03502eeb5c395bc0 (diff) | |
| download | emacs-b905e809274d552c97269a1ac0ace60b0c538476.tar.gz emacs-b905e809274d552c97269a1ac0ace60b0c538476.zip | |
(mac-font-panel-mode): Doc fix.
(mac-service-selection, mac-service-open-file)
(mac-service-open-selection, mac-service-mail-selection)
(mac-service-mail-to, mac-service-insert-text): Rename from
mac-services-*. All uses changed.
(mac-apple-event-map): Rename event symbol `services' to `service'.
| -rw-r--r-- | lisp/term/mac-win.el | 44 |
1 files changed, 23 insertions, 21 deletions
diff --git a/lisp/term/mac-win.el b/lisp/term/mac-win.el index c605c951011..6adbdd11274 100644 --- a/lisp/term/mac-win.el +++ b/lisp/term/mac-win.el | |||
| @@ -79,7 +79,7 @@ | |||
| 79 | (eval-when-compile (require 'url)) | 79 | (eval-when-compile (require 'url)) |
| 80 | 80 | ||
| 81 | (defvar mac-charset-info-alist) | 81 | (defvar mac-charset-info-alist) |
| 82 | (defvar mac-services-selection) | 82 | (defvar mac-service-selection) |
| 83 | (defvar mac-system-script-code) | 83 | (defvar mac-system-script-code) |
| 84 | (defvar mac-apple-event-map) | 84 | (defvar mac-apple-event-map) |
| 85 | (defvar mac-atsu-font-table) | 85 | (defvar mac-atsu-font-table) |
| @@ -1713,7 +1713,7 @@ modifiers, it changes global tool-bar visibility setting." | |||
| 1713 | 1713 | ||
| 1714 | (define-minor-mode mac-font-panel-mode | 1714 | (define-minor-mode mac-font-panel-mode |
| 1715 | "Toggle use of the font panel. | 1715 | "Toggle use of the font panel. |
| 1716 | With numeric ARG, display the panel bar if and only if ARG is positive." | 1716 | With numeric ARG, display the font panel if and only if ARG is positive." |
| 1717 | :init-value nil | 1717 | :init-value nil |
| 1718 | :global t | 1718 | :global t |
| 1719 | :group 'mac | 1719 | :group 'mac |
| @@ -1753,37 +1753,37 @@ With numeric ARG, display the panel bar if and only if ARG is positive." | |||
| 1753 | ) ;; (fboundp 'mac-set-font-panel-visibility) | 1753 | ) ;; (fboundp 'mac-set-font-panel-visibility) |
| 1754 | 1754 | ||
| 1755 | ;;; Services | 1755 | ;;; Services |
| 1756 | (defun mac-services-open-file () | 1756 | (defun mac-service-open-file () |
| 1757 | "Open the file specified by the selection value for Services." | 1757 | "Open the file specified by the selection value for Services." |
| 1758 | (interactive) | 1758 | (interactive) |
| 1759 | (find-file-existing (x-selection-value mac-services-selection))) | 1759 | (find-file-existing (x-selection-value mac-service-selection))) |
| 1760 | 1760 | ||
| 1761 | (defun mac-services-open-selection () | 1761 | (defun mac-service-open-selection () |
| 1762 | "Create a new buffer containing the selection value for Services." | 1762 | "Create a new buffer containing the selection value for Services." |
| 1763 | (interactive) | 1763 | (interactive) |
| 1764 | (switch-to-buffer (generate-new-buffer "*untitled*")) | 1764 | (switch-to-buffer (generate-new-buffer "*untitled*")) |
| 1765 | (insert (x-selection-value mac-services-selection)) | 1765 | (insert (x-selection-value mac-service-selection)) |
| 1766 | (sit-for 0) | 1766 | (sit-for 0) |
| 1767 | (save-buffer) ; It pops up the save dialog. | 1767 | (save-buffer) ; It pops up the save dialog. |
| 1768 | ) | 1768 | ) |
| 1769 | 1769 | ||
| 1770 | (defun mac-services-mail-selection () | 1770 | (defun mac-service-mail-selection () |
| 1771 | "Prepare a mail buffer containing the selection value for Services." | 1771 | "Prepare a mail buffer containing the selection value for Services." |
| 1772 | (interactive) | 1772 | (interactive) |
| 1773 | (compose-mail) | 1773 | (compose-mail) |
| 1774 | (rfc822-goto-eoh) | 1774 | (rfc822-goto-eoh) |
| 1775 | (forward-line 1) | 1775 | (forward-line 1) |
| 1776 | (insert (x-selection-value mac-services-selection) "\n")) | 1776 | (insert (x-selection-value mac-service-selection) "\n")) |
| 1777 | 1777 | ||
| 1778 | (defun mac-services-mail-to () | 1778 | (defun mac-service-mail-to () |
| 1779 | "Prepare a mail buffer to be sent to the selection value for Services." | 1779 | "Prepare a mail buffer to be sent to the selection value for Services." |
| 1780 | (interactive) | 1780 | (interactive) |
| 1781 | (compose-mail (x-selection-value mac-services-selection))) | 1781 | (compose-mail (x-selection-value mac-service-selection))) |
| 1782 | 1782 | ||
| 1783 | (defun mac-services-insert-text () | 1783 | (defun mac-service-insert-text () |
| 1784 | "Insert the selection value for Services." | 1784 | "Insert the selection value for Services." |
| 1785 | (interactive) | 1785 | (interactive) |
| 1786 | (let ((text (x-selection-value mac-services-selection))) | 1786 | (let ((text (x-selection-value mac-service-selection))) |
| 1787 | (if (not buffer-read-only) | 1787 | (if (not buffer-read-only) |
| 1788 | (insert text) | 1788 | (insert text) |
| 1789 | (kill-new text) | 1789 | (kill-new text) |
| @@ -1791,15 +1791,17 @@ With numeric ARG, display the panel bar if and only if ARG is positive." | |||
| 1791 | (substitute-command-keys | 1791 | (substitute-command-keys |
| 1792 | "The text from the Services menu can be accessed with \\[yank]"))))) | 1792 | "The text from the Services menu can be accessed with \\[yank]"))))) |
| 1793 | 1793 | ||
| 1794 | (define-key mac-apple-event-map [services paste] 'mac-services-insert-text) | 1794 | ;; kEventClassService/kEventServicePaste |
| 1795 | (define-key mac-apple-event-map [services perform open-file] | 1795 | (define-key mac-apple-event-map [service paste] 'mac-service-insert-text) |
| 1796 | 'mac-services-open-file) | 1796 | ;; kEventClassService/kEventServicePerform |
| 1797 | (define-key mac-apple-event-map [services perform open-selection] | 1797 | (define-key mac-apple-event-map [service perform open-file] |
| 1798 | 'mac-services-open-selection) | 1798 | 'mac-service-open-file) |
| 1799 | (define-key mac-apple-event-map [services perform mail-selection] | 1799 | (define-key mac-apple-event-map [service perform open-selection] |
| 1800 | 'mac-services-mail-selection) | 1800 | 'mac-service-open-selection) |
| 1801 | (define-key mac-apple-event-map [services perform mail-to] | 1801 | (define-key mac-apple-event-map [service perform mail-selection] |
| 1802 | 'mac-services-mail-to) | 1802 | 'mac-service-mail-selection) |
| 1803 | (define-key mac-apple-event-map [service perform mail-to] | ||
| 1804 | 'mac-service-mail-to) | ||
| 1803 | 1805 | ||
| 1804 | (defun mac-dispatch-apple-event (event) | 1806 | (defun mac-dispatch-apple-event (event) |
| 1805 | "Dispatch EVENT according to the keymap `mac-apple-event-map'." | 1807 | "Dispatch EVENT according to the keymap `mac-apple-event-map'." |