[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] 25/39: pabbrev-mode now sets inhibit-modification-hooks
From: |
Phillip Lord |
Subject: |
[elpa] 25/39: pabbrev-mode now sets inhibit-modification-hooks |
Date: |
Mon, 20 Oct 2014 08:22:41 +0000 |
phillord pushed a commit to branch externals/pabbrev
in repository elpa.
commit 33074a403d90dfe0028f9877ab97c887a62945b2
Author: Phillip Lord <address@hidden>
Date: Thu Sep 11 14:54:49 2014 +0100
pabbrev-mode now sets inhibit-modification-hooks
This was motivated by a nasty interaction with linked-buffer
but should be general.
---
pabbrev.el | 14 ++++++++++----
1 files changed, 10 insertions(+), 4 deletions(-)
diff --git a/pabbrev.el b/pabbrev.el
index aa0e24e..6c1e9ce 100644
--- a/pabbrev.el
+++ b/pabbrev.el
@@ -469,10 +469,16 @@ I'm not telling you which version, I prefer."
(defmacro pabbrev-save-buffer-modified-p (&rest body)
"Eval BODY without affected buffer modification status"
- `(let ((buffer-modified (buffer-modified-p))
- (buffer-undo-list t))
- ,@body
- (set-buffer-modified-p buffer-modified)))
+ `(unwind-protect
+ (progn
+ ;; inhibit modification hooks to avoid nasty interaction
+ ;; with linked-buffer.el
+ (setq inhibit-modification-hooks t)
+ (let ((buffer-modified (buffer-modified-p))
+ (buffer-undo-list t))
+ ,@body
+ (set-buffer-modified-p buffer-modified)))
+ (setq inhibit-modification-hooks nil)))
(defun pabbrev-get-usage-hash()
"Returns the usage hash for this buffer."
- [elpa] 15/39: Documentation Updates., (continued)
- [elpa] 15/39: Documentation Updates., Phillip Lord, 2014/10/20
- [elpa] 13/39: Initial Checkin, Phillip Lord, 2014/10/20
- [elpa] 17/39: Version number added. Documentation fix. Indentation fix., Phillip Lord, 2014/10/20
- [elpa] 05/39: Ported from generic.el to define-derived-mode. Comment-character is now "#" rather than fudged "# " Delimited URIs now recognised as strings Electric indentation added. Indentation engine improved., Phillip Lord, 2014/10/20
- [elpa] 20/39: New keywords added., Phillip Lord, 2014/10/20
- [elpa] 18/39: Copes better with missing repos. Improved output., Phillip Lord, 2014/10/20
- [elpa] 19/39: Markdown support added., Phillip Lord, 2014/10/20
- [elpa] 21/39: Exclude nrepl mode., Phillip Lord, 2014/10/20
- [elpa] 14/39: Initial checkin., Phillip Lord, 2014/10/20
- [elpa] 23/39: Some code re-organisation. Checks whether pulse.el can cope with foreground pulse., Phillip Lord, 2014/10/20
- [elpa] 25/39: pabbrev-mode now sets inhibit-modification-hooks,
Phillip Lord <=
- [elpa] 26/39: Improved keyboard handling., Phillip Lord, 2014/10/20
- [elpa] 22/39: Initial checkin, Phillip Lord, 2014/10/20
- [elpa] 27/39: Add cider-nrepl mode to ignored., Phillip Lord, 2014/10/20
- [elpa] 24/39: Keywords, Status added., Phillip Lord, 2014/10/20
- [elpa] 32/39: README.md added., Phillip Lord, 2014/10/20
- [elpa] 34/39: Version 4.0, Phillip Lord, 2014/10/20
- [elpa] 02/39: Initial checking to mercurial, Phillip Lord, 2014/10/20
- [elpa] 33/39: README.md update for version 4.0, Phillip Lord, 2014/10/20
- [elpa] 01/39: Initial checkin to Mercurial, Phillip Lord, 2014/10/20
- [elpa] 39/39: Set version to 0 for ELPA., Phillip Lord, 2014/10/20