[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r110823: * notifications.el (notifica
From: |
Michael Albinus |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r110823: * notifications.el (notifications-get-server-information-method): |
Date: |
Wed, 07 Nov 2012 17:55:39 +0100 |
User-agent: |
Bazaar (2.5.0) |
------------------------------------------------------------
revno: 110823
committer: Michael Albinus <address@hidden
branch nick: trunk
timestamp: Wed 2012-11-07 17:55:39 +0100
message:
* notifications.el (notifications-get-server-information-method):
New defconst.
(notifications-get-capabilities): Fix docstring.
(notifications-get-server-information): New defun.
modified:
lisp/ChangeLog
lisp/notifications.el
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2012-11-06 16:33:56 +0000
+++ b/lisp/ChangeLog 2012-11-07 16:55:39 +0000
@@ -1,3 +1,10 @@
+2012-11-07 Michael Albinus <address@hidden>
+
+ * notifications.el (notifications-get-server-information-method):
+ New defconst.
+ (notifications-get-capabilities): Fix docstring.
+ (notifications-get-server-information): New defun.
+
2012-11-06 Agustín Martín Domingo <address@hidden>
* textmodes/ispell.el (ispell-region): Standard re-indent for better
=== modified file 'lisp/notifications.el'
--- a/lisp/notifications.el 2012-07-27 10:56:03 +0000
+++ b/lisp/notifications.el 2012-11-07 16:55:39 +0000
@@ -66,6 +66,9 @@
(defconst notifications-get-capabilities-method "GetCapabilities"
"D-Bus notifications get capabilities method.")
+(defconst notifications-get-server-information-method "GetServerInformation"
+ "D-Bus notifications get server information method.")
+
(defconst notifications-action-signal "ActionInvoked"
"D-Bus notifications action signal.")
@@ -349,7 +352,7 @@
(defvar dbus-debug) ; used in the macroexpansion of dbus-ignore-errors
(defun notifications-get-capabilities (&optional bus)
- "Return the capabilities of the notification server, a list of strings.
+ "Return the capabilities of the notification server, a list of symbols.
BUS can be a string denoting a D-Bus connection, the default is `:session'.
The following capabilities can be expected:
@@ -371,12 +374,34 @@
Further vendor-specific caps start with `:x-vendor', like `:x-gnome-foo-cap'."
(dbus-ignore-errors
- (mapcar
- (lambda (x) (intern (concat ":" x)))
+ (mapcar
+ (lambda (x) (intern (concat ":" x)))
+ (dbus-call-method (or bus :session)
+ notifications-service
+ notifications-path
+ notifications-interface
+ notifications-get-capabilities-method))))
+
+(defun notifications-get-server-information (&optional bus)
+ "Return information on the notification server, a list of strings.
+BUS can be a string denoting a D-Bus connection, the default is `:session'.
+The returned list is (NAME VENDOR VERSION SPEC-VERSION).
+
+ NAME The product name of the server.
+ VENDOR The vendor name. For example, \"KDE\", \"GNOME\".
+ VERSION The server's version number.
+ SPEC-VERSION The specification version the server is compliant with.
+
+If SPEC_VERSION is missing, the server supports a specification
+prior to \"1.0\".
+
+See `notifications-specification-version' for the specification
+version this library is compliant with."
+ (dbus-ignore-errors
(dbus-call-method (or bus :session)
notifications-service
notifications-path
notifications-interface
- notifications-get-capabilities-method))))
+ notifications-get-server-information-method)))
(provide 'notifications)
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r110823: * notifications.el (notifications-get-server-information-method):,
Michael Albinus <=