[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/bluetooth 950cc77 27/33: add more menu entries
From: |
Stefan Monnier |
Subject: |
[elpa] externals/bluetooth 950cc77 27/33: add more menu entries |
Date: |
Sat, 19 Sep 2020 08:43:25 -0400 (EDT) |
branch: externals/bluetooth
commit 950cc7740757d8b0b2f9cca46cf7f6353d0df521
Author: Raffael Stocker <r.stocker@mnet-mail.de>
Commit: Raffael Stocker <r.stocker@mnet-mail.de>
add more menu entries
---
bluetooth.el | 36 ++++++++++++++++++++++++++++++++++--
1 file changed, 34 insertions(+), 2 deletions(-)
diff --git a/bluetooth.el b/bluetooth.el
index d5e93e8..eff3247 100644
--- a/bluetooth.el
+++ b/bluetooth.el
@@ -12,8 +12,6 @@
;; Keywords: hardware
;; URL: https://gitlab.com/rstocker/emacs-bluetooth
-;; This file is part of GNU Emacs
-
;; GNU Emacs is free software: you can redistribute it and/or modify
;; it under the terms of the GNU General Public License as published by
;; the Free Software Foundation, either version 3 of the License, or (at
@@ -189,6 +187,19 @@ profiles."
(bluetooth--dbus-method "DisconnectProfile" :device (car uuid))
(bluetooth--dbus-method "Disconnect" :device)))
+(defun bluetooth-connect-profile ()
+ "Ask for a Bluetooth profile and connect the device at point to it."
+ (interactive)
+ (let ((prefix-arg (list 4)))
+ (command-execute #'bluetooth-connect)))
+
+(defun bluetooth-disconnect-profile ()
+ "Ask for a Bluetooth profile and disconnect the device at point from it."
+ (interactive)
+ (let ((prefix-arg (list 4)))
+ (command-execute #'bluetooth-disconnect)))
+
+
(defmacro bluetooth-defun-method (method api docstring)
(declare (doc-string 3) (indent 2))
(let ((name (bluetooth--function-name method)))
@@ -270,6 +281,12 @@ profiles."
(define-key map [menu-bar bluetooth device]
(cons "Device" (make-sparse-keymap "Device")))
+ (define-key map [menu-bar bluetooth stop-discovery]
+ '(menu-item "Stop discovery" bluetooth-stop-discovery
+ :help "Stop discovery"))
+ (define-key map [menu-bar bluetooth start-discovery]
+ '(menu-item "Start discovery" bluetooth-start-discovery
+ :help "Start discovery"))
(define-key map [menu-bar bluetooth toggle-discoverable]
'(menu-item "Toggle discoverable" bluetooth-toggle-discoverable
:help "Toggle discoverable mode"))
@@ -280,18 +297,33 @@ profiles."
'(menu-item "Toggle powered" bluetooth-toggle-powered
:help "Toggle power supply of adapter"))
+ (define-key map [menu-bar bluetooth device show-info]
+ '(menu-item "Show device info" bluetooth-show-device-info
+ :help "Show bluetooth device info"))
+ (define-key map [menu-bar bluetooth device set-alias]
+ '(menu-item "Set device alias" bluetooth-set-alias
+ :help "Set device alias"))
(define-key map [menu-bar bluetooth device toggle-trusted]
'(menu-item "Toggle trusted" bluetooth-toggle-trusted
:help "Trust/untrust bluetooth device"))
(define-key map [menu-bar bluetooth device toggle-blocked]
'(menu-item "Toggle blocked" bluetooth-toggle-blocked
:help "Block/unblock bluetooth device"))
+ (define-key map [menu-bar bluetooth device disconnect-profile]
+ '(menu-item "Disconnect profile" bluetooth-disconnect-profile
+ :help "Disconnect bluetooth device profile"))
(define-key map [menu-bar bluetooth device disconnect]
'(menu-item "Disconnect" bluetooth-disconnect
:help "Disconnect bluetooth device"))
+ (define-key map [menu-bar bluetooth device connect-profile]
+ '(menu-item "Connect profile" bluetooth-connect-profile
+ :help "Connect bluetooth device profile"))
(define-key map [menu-bar bluetooth device connect]
'(menu-item "Connect" bluetooth-connect
:help "Connect bluetooth device"))
+ (define-key map [menu-bar bluetooth device remove]
+ '(menu-item "Remove" bluetooth-remove-device
+ :help "Remove bluetooth device"))
(define-key map [menu-bar bluetooth device pair]
'(menu-item "Pair" bluetooth-pair
:help "Pair bluetooth device"))
- [elpa] externals/bluetooth eb4b158 15/33: Merge commit 'f107d6f', (continued)
- [elpa] externals/bluetooth eb4b158 15/33: Merge commit 'f107d6f', Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth b12caf1 16/33: update author list, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 5d72618 17/33: add page breaks and section headings, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 8e8b6d0 19/33: bump up the copyright year, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 943ddf3 21/33: Clean up the UUID and class descriptions, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 98afd71 22/33: add property and uuid functions, update info display, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 518ebdf 29/33: update company ids (bluetooth--manufacturer-ids), Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 2746c62 23/33: change connect and disconnect functions to handle single profiles, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 0ca89cf 24/33: clean up the connect and disconnect functions, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 7bb793f 26/33: remove unneeded hydra reference from Makefile, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 950cc77 27/33: add more menu entries,
Stefan Monnier <=
- [elpa] externals/bluetooth b5fc5c2 28/33: correct docstring in bluetooth-disconnect, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 28d16f6 33/33: set version number to 0.2, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth dc4b63b 30/33: correct docstrings, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 6599093 31/33: update list of member UUIDs (bluetooth--member-uuid-alist)., Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth 2ae073b 25/33: update readme with single profile connect information, Stefan Monnier, 2020/09/19
- [elpa] externals/bluetooth eebb593 32/33: refactor variable names of hash tables (were: -alist), Stefan Monnier, 2020/09/19