aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Albinus2009-07-03 14:54:14 +0000
committerMichael Albinus2009-07-03 14:54:14 +0000
commitf0dbdc25ca83b4d82c9626e050c05580f5bc8672 (patch)
tree2008ae77e3b7342505f43459597bf7848bb0aa8d
parent809041200302d2c45058d6b9be04345e88571040 (diff)
downloademacs-f0dbdc25ca83b4d82c9626e050c05580f5bc8672.tar.gz
emacs-f0dbdc25ca83b4d82c9626e050c05580f5bc8672.zip
* net/tramp-gvfs.el (tramp-gvfs-methods)
(tramp-gvfs-zeroconf-domain) (tramp-bluez-discover-devices-timeout): Add version flag. (tramp-gvfs-handler-mounted-unmounted) (tramp-gvfs-connection-mounted-p): Polish handling of incompatibilities between GVFS 0.2 and 1.0.
-rw-r--r--lisp/ChangeLog9
-rw-r--r--lisp/net/tramp-gvfs.el26
2 files changed, 22 insertions, 13 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 72a512967b1..0f05c2e3e98 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,12 @@
12009-07-03 Michael Albinus <michael.albinus@gmx.de>
2
3 * net/tramp-gvfs.el (tramp-gvfs-methods)
4 (tramp-gvfs-zeroconf-domain)
5 (tramp-bluez-discover-devices-timeout): Add version flag.
6 (tramp-gvfs-handler-mounted-unmounted)
7 (tramp-gvfs-connection-mounted-p): Polish handling of
8 incompatibilities between GVFS 0.2 and 1.0.
9
12009-07-03 Jan Djärv <jan.h.d@swipnet.se> 102009-07-03 Jan Djärv <jan.h.d@swipnet.se>
2 11
3 * cus-start.el (all): Added make-pointer-invisible. 12 * cus-start.el (all): Added make-pointer-invisible.
diff --git a/lisp/net/tramp-gvfs.el b/lisp/net/tramp-gvfs.el
index 9241541a8e2..e4499a52f83 100644
--- a/lisp/net/tramp-gvfs.el
+++ b/lisp/net/tramp-gvfs.el
@@ -23,12 +23,15 @@
23;;; Commentary: 23;;; Commentary:
24 24
25;; Access functions for the GVFS daemon from Tramp. Tested with GVFS 25;; Access functions for the GVFS daemon from Tramp. Tested with GVFS
26;; 1.0.2 (Ubuntu 8.10, Gnome 2.24). 26;; 1.0.2 (Ubuntu 8.10, Gnome 2.24). It has been reported also to run
27;; with GVFS 0.2.5 (Ubuntu 8.04, Gnome 2.22), but there is an
28;; incompatibility with the mount_info structure, which has been
29;; worked around.
27 30
28;; All actions to mount a remote location, and to retrieve mount 31;; All actions to mount a remote location, and to retrieve mount
29;; information, are performed by D-Bus messages. File operations 32;; information, are performed by D-Bus messages. File operations
30;; themselves are performed via the mounted filesystem in ~/.gvfs. 33;; themselves are performed via the mounted filesystem in ~/.gvfs.
31;; Consequently, GNU Emacs 23.0.90 with enabled D-Bus bindings is a 34;; Consequently, GNU Emacs 23.1 with enabled D-Bus bindings is a
32;; precondition. 35;; precondition.
33 36
34;; The GVFS D-Bus interface is said to be instable. There are even no 37;; The GVFS D-Bus interface is said to be instable. There are even no
@@ -102,6 +105,7 @@
102(defcustom tramp-gvfs-methods '("dav" "davs" "obex" "synce") 105(defcustom tramp-gvfs-methods '("dav" "davs" "obex" "synce")
103 "*List of methods for remote files, accessed with GVFS." 106 "*List of methods for remote files, accessed with GVFS."
104 :group 'tramp 107 :group 'tramp
108 :version "23.2"
105 :type '(repeat (choice (const "dav") 109 :type '(repeat (choice (const "dav")
106 (const "davs") 110 (const "davs")
107 (const "ftp") 111 (const "ftp")
@@ -118,6 +122,7 @@
118(defcustom tramp-gvfs-zeroconf-domain "local" 122(defcustom tramp-gvfs-zeroconf-domain "local"
119 "*Zeroconf domain to be used for discovering services, like host names." 123 "*Zeroconf domain to be used for discovering services, like host names."
120 :group 'tramp 124 :group 'tramp
125 :version "23.2"
121 :type 'string) 126 :type 'string)
122 127
123;; Add the methods to `tramp-methods', in order to allow minibuffer 128;; Add the methods to `tramp-methods', in order to allow minibuffer
@@ -175,7 +180,7 @@
175;; OBJECT_PATH object_path 180;; OBJECT_PATH object_path
176;; STRING display_name 181;; STRING display_name
177;; STRING stable_name 182;; STRING stable_name
178;; STRING x_content_types 183;; STRING x_content_types Since GVFS 1.0 only !!!
179;; STRING icon 184;; STRING icon
180;; STRING prefered_filename_encoding 185;; STRING prefered_filename_encoding
181;; BOOLEAN user_visible 186;; BOOLEAN user_visible
@@ -333,6 +338,7 @@ A value of 0 would require an immediate discovery during hostname
333completion, nil means to use always cached values for discovered 338completion, nil means to use always cached values for discovered
334devices." 339devices."
335 :group 'tramp 340 :group 'tramp
341 :version "23.2"
336 :type '(choice (const nil) integer)) 342 :type '(choice (const nil) integer))
337 343
338(defvar tramp-bluez-discovery nil 344(defvar tramp-bluez-discovery nil
@@ -869,10 +875,7 @@ ADDRESS can have the form \"xx:xx:xx:xx:xx:xx\" or \"[xx:xx:xx:xx:xx:xx]\"."
869\"org.gtk.vfs.MountTracker.unmounted\" signals." 875\"org.gtk.vfs.MountTracker.unmounted\" signals."
870 (ignore-errors 876 (ignore-errors
871 (let* ((signal-name (dbus-event-member-name last-input-event)) 877 (let* ((signal-name (dbus-event-member-name last-input-event))
872 ;; The interface of mount-info has been changed. We must 878 (mount-spec (cadar (last mount-info)))
873 ;; handle both cases.
874 (last-nth (if (nth 9 mount-info) 9 8))
875 (mount-spec (nth 1 (nth last-nth mount-info)))
876 (method (dbus-byte-array-to-string (cadr (assoc "type" mount-spec)))) 879 (method (dbus-byte-array-to-string (cadr (assoc "type" mount-spec))))
877 (user (dbus-byte-array-to-string (cadr (assoc "user" mount-spec)))) 880 (user (dbus-byte-array-to-string (cadr (assoc "user" mount-spec))))
878 (domain (dbus-byte-array-to-string 881 (domain (dbus-byte-array-to-string
@@ -901,7 +904,7 @@ ADDRESS can have the form \"xx:xx:xx:xx:xx:xx\" or \"[xx:xx:xx:xx:xx:xx]\"."
901 (tramp-set-file-property 904 (tramp-set-file-property
902 v "/" "fuse-mountpoint" 905 v "/" "fuse-mountpoint"
903 (file-name-nondirectory 906 (file-name-nondirectory
904 (dbus-byte-array-to-string (nth (1- last-nth) mount-info))))))))) 907 (dbus-byte-array-to-string (car (last mount-info 2))))))))))
905 908
906(dbus-register-signal 909(dbus-register-signal
907 :session nil tramp-gvfs-path-mounttracker 910 :session nil tramp-gvfs-path-mounttracker
@@ -923,10 +926,7 @@ ADDRESS can have the form \"xx:xx:xx:xx:xx:xx\" or \"[xx:xx:xx:xx:xx:xx]\"."
923 :session tramp-gvfs-service-daemon tramp-gvfs-path-mounttracker 926 :session tramp-gvfs-service-daemon tramp-gvfs-path-mounttracker
924 tramp-gvfs-interface-mounttracker "listMounts")) 927 tramp-gvfs-interface-mounttracker "listMounts"))
925 nil) 928 nil)
926 ;; The interface of mount-info has been changed. We must handle 929 (let* ((mount-spec (cadar (last elt)))
927 ;; both cases.
928 (let* ((last-nth (if (nth 9 elt) 9 8))
929 (mount-spec (nth 1 (nth last-nth elt)))
930 (method (dbus-byte-array-to-string 930 (method (dbus-byte-array-to-string
931 (cadr (assoc "type" mount-spec)))) 931 (cadr (assoc "type" mount-spec))))
932 (user (dbus-byte-array-to-string 932 (user (dbus-byte-array-to-string
@@ -957,7 +957,7 @@ ADDRESS can have the form \"xx:xx:xx:xx:xx:xx\" or \"[xx:xx:xx:xx:xx:xx]\"."
957 (tramp-set-file-property 957 (tramp-set-file-property
958 vec "/" "fuse-mountpoint" 958 vec "/" "fuse-mountpoint"
959 (file-name-nondirectory 959 (file-name-nondirectory
960 (dbus-byte-array-to-string (nth (1- last-nth) elt)))) 960 (dbus-byte-array-to-string (car (last elt 2)))))
961 (throw 'mounted t)))))) 961 (throw 'mounted t))))))
962 962
963(defun tramp-gvfs-mount-spec (vec) 963(defun tramp-gvfs-mount-spec (vec)