summaryrefslogtreecommitdiff
path: root/lisp/term/x-win.el
diff options
context:
space:
mode:
authorJan Djärv <jan.h.d@swipnet.se>2004-02-03 16:55:30 +0000
committerJan Djärv <jan.h.d@swipnet.se>2004-02-03 16:55:30 +0000
commit133aad747dac3476722b7c75ef1578e2e905d8f9 (patch)
treec55c2e9a67043a4037c0d53dd66fb218d7a4f3f5 /lisp/term/x-win.el
parent69eff41f7eea76db81a9e4a441d7daf747a3cf68 (diff)
downloademacs-133aad747dac3476722b7c75ef1578e2e905d8f9.tar.gz
* x-dnd.el: New file for drag and drop.
* term/x-win.el: require x-dnd, set after-make-frame-functions to x-dnd-init-frame, let x-dnd-handle-drag-n-drop-event handle drag-n-drop event. * dired.el (dired-dnd-test-function, dired-dnd-popup-notice) (dired-dnd-do-ask-action, dired-dnd-handle-local-file) (dired-dnd-handle-file): New functions for drag and drop support. (dired-mode): Initialize drag and drop if x-dnd present.
Diffstat (limited to 'lisp/term/x-win.el')
-rw-r--r--lisp/term/x-win.el6
1 files changed, 6 insertions, 0 deletions
diff --git a/lisp/term/x-win.el b/lisp/term/x-win.el
index 0e6d9be3f7d..09657fb848f 100644
--- a/lisp/term/x-win.el
+++ b/lisp/term/x-win.el
@@ -76,6 +76,7 @@
(require 'select)
(require 'menu-bar)
(require 'fontset)
+(require 'x-dnd)
(defvar x-invocation-args)
@@ -2452,6 +2453,7 @@ order until succeed.")
;; Turn on support for mouse wheels.
(mouse-wheel-mode 1)
+
;; Enable CLIPBOARD copy/paste through menu bar commands.
(menu-bar-enable-clipboard)
@@ -2469,5 +2471,9 @@ order until succeed.")
(cons "Paste" (cons "Paste text from clipboard or kill ring"
'x-clipboard-yank)))
+;; Initiate drag and drop
+(add-hook 'after-make-frame-functions 'x-dnd-init-frame)
+(global-set-key [drag-n-drop] 'x-dnd-handle-drag-n-drop-event)
+
;;; arch-tag: f1501302-db8b-4d95-88e3-116697d89f78
;;; x-win.el ends here