[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/eglot-inactive-regions 7e4eb584e0 61/66: fallback to depre
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/eglot-inactive-regions 7e4eb584e0 61/66: fallback to deprecated functions |
Date: |
Fri, 6 Dec 2024 06:59:58 -0500 (EST) |
branch: elpa/eglot-inactive-regions
commit 7e4eb584e0a8d344deae9d22673cb2bc84baea95
Author: Filippo Argiolas <filippo.argiolas@gmail.com>
Commit: Filippo Argiolas <filippo.argiolas@gmail.com>
fallback to deprecated functions
---
eglot-inactive-regions.el | 16 ++++++++++++++--
1 file changed, 14 insertions(+), 2 deletions(-)
diff --git a/eglot-inactive-regions.el b/eglot-inactive-regions.el
index cd36a1a166..cb0deb549c 100644
--- a/eglot-inactive-regions.el
+++ b/eglot-inactive-regions.el
@@ -297,9 +297,21 @@ Useful to update colors after a face or theme change."
(setq eglot-inactive-regions--active nil)))
(remove-hook 'change-major-mode-hook #'eglot-inactive-regions-cleanup))
+(defun eglot-inactive-regions--uri-to-path (uri)
+ "Fallback to deprecated uri-to-path URI if new function is not available."
+ (if (fboundp 'eglot-uri-to-path)
+ (eglot-uri-to-path uri)
+ (eglot--uri-to-path uri)))
+
+(defun eglot-inactive-regions--range-region (range)
+ "Fallback to deprecated range-region RANGE if new function is not available."
+ (if (fboundp 'eglot-range-region)
+ (eglot-range-region range)
+ (eglot--range-region range)))
+
(defun eglot-inactive-regions--handle-notification (uri regions)
"Update inactive REGIONS for the buffer corresponding to URI."
- (when-let* ((path (expand-file-name (eglot--uri-to-path uri)))
+ (when-let* ((path (expand-file-name (eglot-inactive-regions--uri-to-path
uri)))
(buffer (find-buffer-visiting path)))
(with-current-buffer buffer
(when eglot-inactive-regions-mode
@@ -308,7 +320,7 @@ Useful to update colors after a face or theme change."
(setq eglot-inactive-regions--ranges '())
(cl-loop
for r across regions
- for (beg . end) = (eglot--range-region r)
+ for (beg . end) = (eglot-inactive-regions--range-region r)
do
(push (cons beg end) eglot-inactive-regions--ranges))
(eglot-inactive-regions-refresh)))))
- [nongnu] elpa/eglot-inactive-regions 5d1580f32b 38/66: fix docs and bump version, (continued)
- [nongnu] elpa/eglot-inactive-regions 5d1580f32b 38/66: fix docs and bump version, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions cd53f3244a 56/66: rename darken-foreground dimmed faces, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 437d09e552 53/66: revert to deprecated eglot functions, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions bf51947630 55/66: prefer when-let if no else clause is needed, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 193827fdeb 58/66: missing clangd references after rename, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 5c20f58422 60/66: clean up after review on emacs-devel, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 80c1b60009 44/66: Revert "revert to deprecated eglot functions", ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 26f3b61b45 51/66: readme update, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions badb4e403a 46/66: cleanup on major mode changes, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions a810593308 59/66: bump version to 0.6, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 7e4eb584e0 61/66: fallback to deprecated functions,
ELPA Syncer <=
- [nongnu] elpa/eglot-inactive-regions 6ac373dfd0 62/66: bump version after emacs-devel review, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 3569bd5dc7 24/66: Properly enable/clean up state on minor mode toggle, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 3b248e0684 37/66: Update install section in README.md, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 3ca295f189 45/66: switch to global minor mode, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 15259e94b2 50/66: move to defcustoms for customization, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 5b48f4940d 54/66: rename shading method to shading style, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 2d93c0cab0 04/66: forgot some package comment, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 3cb6ed0bc4 34/66: update README.md, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 5e08869dd6 36/66: Bump version to 0.3, ELPA Syncer, 2024/12/06
- [nongnu] elpa/eglot-inactive-regions 89ffc22d6f 49/66: rename main package file, ELPA Syncer, 2024/12/06