[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/bluetooth f0e5047 18/57: removes unnecessary quotes bef
From: |
Stefan Monnier |
Subject: |
[elpa] externals/bluetooth f0e5047 18/57: removes unnecessary quotes before lambdas and corrects indentation |
Date: |
Thu, 7 Nov 2019 23:28:51 -0500 (EST) |
branch: externals/bluetooth
commit f0e5047793338e81689aa22d298d42ec295c0882
Author: Raffael Stocker <address@hidden>
Commit: Raffael Stocker <address@hidden>
removes unnecessary quotes before lambdas and corrects indentation
---
bluetooth.el | 62 ++++++++++++++++++++++++++++++------------------------------
1 file changed, 31 insertions(+), 31 deletions(-)
diff --git a/bluetooth.el b/bluetooth.el
index 41204ea..30d4a76 100644
--- a/bluetooth.el
+++ b/bluetooth.el
@@ -97,13 +97,13 @@
;;; The path-spec is a list of functions, defined below, that
;;; return the designated constituents of the D-Bus path.
(defconst bluetooth--api-info '(:device
- (:path
- (bluetooth--adapter bluetooth--device)
- :interface "org.bluez.Device1")
- :adapter
- (:path
- (bluetooth--adapter)
- :interface "org.bluez.Adapter1"))
+ (:path
+ (bluetooth--adapter bluetooth--device)
+ :interface "org.bluez.Device1")
+ :adapter
+ (:path
+ (bluetooth--adapter)
+ :interface "org.bluez.Adapter1"))
"Bluez D-Bus API information about paths and interfaces.")
;;; The following functions provide the constituents of the path
@@ -219,9 +219,9 @@ devices, as well as setting properties."
;;; by a list of devices known to this adapter.
(defun bluetooth--get-devices ()
"Return a list of bluetooth adapters and devices connected to them."
- (mapcar #'(lambda (a)
- (list a (dbus-introspect-get-node-names
- :system bluetooth--service (concat bluetooth--root "/"
a))))
+ (mapcar (lambda (a)
+ (list a (dbus-introspect-get-node-names
+ :system bluetooth--service (concat bluetooth--root "/"
a))))
(dbus-introspect-get-node-names
:system bluetooth--service bluetooth--root)))
@@ -243,14 +243,14 @@ devices, as well as setting properties."
(defun bluetooth--get-device-info (devices)
"Return a list with information about DEVICES."
(mapcan
- #'(lambda (devlist)
- (cl-loop for dev in (cadr devlist)
- for path = (mapconcat #'identity
- (list bluetooth--root (car devlist) dev)
- "/")
- collect (cons dev (list (dbus-get-all-properties
- :system bluetooth--service path
- "org.bluez.Device1")))))
+ (lambda (devlist)
+ (cl-loop for dev in (cadr devlist)
+ for path = (mapconcat #'identity
+ (list bluetooth--root (car devlist) dev)
+ "/")
+ collect (cons dev (list (dbus-get-all-properties
+ :system bluetooth--service path
+ "org.bluez.Device1")))))
devices))
(defun bluetooth--dev-state (key device)
@@ -264,10 +264,10 @@ devices, as well as setting properties."
;;; format needed by `tabulated-list-print'.
(defun bluetooth--compile-list-entries (device-info)
"Compile list entries based on previously gathered DEVICE-INFO."
- (mapcar #'(lambda (dev)
- (list (car dev)
- (cl-map 'vector #'(lambda (key) (bluetooth--dev-state key
dev))
- (mapcar #'car bluetooth--list-format))))
+ (mapcar (lambda (dev)
+ (list (car dev)
+ (cl-map 'vector (lambda (key) (bluetooth--dev-state key dev))
+ (mapcar #'car bluetooth--list-format))))
device-info))
;;; Build up the index for Imenu. This function is used as
@@ -284,12 +284,12 @@ devices, as well as setting properties."
;;; Bluez API. This is used on D-Bus functions.
(defun bluetooth--call-method (dev-id api function &rest args)
"For DEV-ID, invoke D-Bus FUNCTION on API, passing ARGS."
- (let ((path (mapconcat #'(lambda (f) (funcall f dev-id))
+ (let ((path (mapconcat (lambda (f) (funcall f dev-id))
(plist-get (plist-get bluetooth--api-info api) :path)
"/"))
(interface (plist-get (plist-get bluetooth--api-info api) :interface)))
(apply function :system bluetooth--service path interface
- (mapcar #'(lambda (x) (if (eq x :path-devid) (concat path "/"
dev-id) x))
+ (mapcar (lambda (x) (if (eq x :path-devid) (concat path "/" dev-id)
x))
args))))
;;; The following functions are the workers for the commands.
@@ -300,7 +300,7 @@ devices, as well as setting properties."
"Invoke METHOD on D-Bus API with ARGS."
(apply #'bluetooth--call-method (tabulated-list-get-id) api
#'dbus-call-method-asynchronously method
- #'(lambda () (tabulated-list-print t)) :timeout bluetooth--timeout
args))
+ (lambda () (tabulated-list-print t)) :timeout bluetooth--timeout args))
;;; Toggle a property.
(defun bluetooth--dbus-toggle (property api)
@@ -335,7 +335,7 @@ devices, as well as setting properties."
,@ .run))
(.toggle `(lambda () (interactive)
(let ((value (bluetooth--dbus-toggle , .toggle , .api)))
- ,@ .run)))
+ ,@ .run)))
(.set `(lambda (arg) (interactive ,(concat "M" .query))
(bluetooth--dbus-set , .set arg , .api)
,@ .run)))
@@ -352,8 +352,8 @@ This function only uses the first adapter reported by
Bluez."
(car adapters))
"org.bluez.Adapter1"))
(info (mapconcat #'identity
- (-keep #'(lambda (x) (if (cdr (assoc (car x) resp))
- (cadr x) (caddr x)))
+ (-keep (lambda (x) (if (cdr (assoc (car x) resp))
+ (cadr x) (caddr x)))
bluetooth--mode-state)
",")))
(unless (string-blank-p info)
@@ -408,8 +408,8 @@ This function only uses the first adapter reported by
Bluez."
`org.bluez.Error.Rejected' is issued if BODY evaluates to nil."
(declare (indent defun))
`(or (condition-case nil
- ,@body
- (quit (signal 'dbus-error '("org.bluez.Error.Canceled"))))
+ ,@body
+ (quit (signal 'dbus-error '("org.bluez.Error.Canceled"))))
(signal 'dbus-error '("org.bluez.Error.Rejected"))))
(defun bluetooth--request-pin-code (device)
@@ -497,7 +497,7 @@ This function only uses the first adapter reported by
Bluez."
for fname = (concat "bluetooth-"
(replace-regexp-in-string
"[A-Z][a-z]+"
- #'(lambda (x) (concat "-" (downcase x)))
+ (lambda (x) (concat "-" (downcase x)))
method t))
collect (dbus-register-method :session dbus-service-emacs
bluetooth--own-path
- [elpa] externals/bluetooth cc33d79 14/57: corrects project name in LICENSE, (continued)
- [elpa] externals/bluetooth cc33d79 14/57: corrects project name in LICENSE, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 3743458 17/57: corrects list redisplay when mode is restarted, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 8cac69d 26/57: checks list-id for nil to avoid errors at actions w/o list item, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 4a40ee6 24/57: adds GATT UUIDs and a rudimentary display function, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth f33cb12 02/57: Add LICENSE, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth ee4e582 30/57: fixes compiler warnings about unused parameters, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 3365413 33/57: corrects the major mode check in `list-bluetooth-devices', Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth b47bddc 36/57: switches device-info buffer to special mode, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 42a9487 35/57: moves `hl-line-mode' to end of init so hl is shown at startup, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 325febd 16/57: adds Imenu integration to Readme feature list, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth f0e5047 18/57: removes unnecessary quotes before lambdas and corrects indentation,
Stefan Monnier <=
- [elpa] externals/bluetooth 738347b 19/57: adds TAGS to .gitignore, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 28e9eb2 21/57: wraps @body in progn in bluetooth--maybe-cancel-reject, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 4133a10 13/57: makes mode idempotent, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 3c25a8c 23/57: adds basic service class UUID parsing, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 5219f05 31/57: fixes a compile error and adds customization, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 0108cbd 32/57: uses `read-from-minibuffer' instead of `read-passwd', Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 1ec2997 22/57: uses the correct bus (:system) for the callback methods, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 83344c8 20/57: cleans up display code, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth fe926e9 28/57: puts functions before the long uuid defconsts for readability, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth c473128 40/57: adds repository URL to mode (entry) command docstring, Stefan Monnier, 2019/11/07