aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorforcer <forcer>2005-09-20 18:57:00 +0000
committerforcer <mwolson@gnu.org>2005-09-20 18:57:00 +0000
commitfa77f2c443f817f06bc7f0840b8c72de499bd10e (patch)
treea63794b43eb163b2fe3c08f3d40b81f8eb71ab82
parent4419434e68690130ed655c3aa82d93573f17c151 (diff)
Ignore read-onliness when updating a track in a playlist buffer
darcs-hash:20050920185705-2189f-fdbbe3e722c0ea46c44d0e7a3c173618ff00ca46.gz
-rw-r--r--emms-playlist-mode.el18
1 files changed, 10 insertions, 8 deletions
diff --git a/emms-playlist-mode.el b/emms-playlist-mode.el
index f7da6a7..ce44b36 100644
--- a/emms-playlist-mode.el
+++ b/emms-playlist-mode.el
@@ -298,14 +298,16 @@ of the saved playlist inside."
(defun emms-playlist-mode-update-track-function ()
"Update the track display at point."
(emms-playlist-ensure-playlist-buffer)
- (let ((track-region (emms-property-region (point-at-bol)
- 'emms-track))
- (track (get-text-property (point-at-bol)
- 'emms-track)))
- (delete-region (car track-region)
- ;; 1+ For the \n
- (1+ (cdr track-region)))
- (emms-playlist-mode-insert-track track)))
+ (let ((inhibit-read-only t))
+ (let ((track-region (emms-property-region (point-at-bol)
+ 'emms-track))
+ (track (get-text-property (point-at-bol)
+ 'emms-track)))
+ (save-excursion
+ (delete-region (car track-region)
+ ;; 1+ For the \n
+ (1+ (cdr track-region)))
+ (emms-playlist-mode-insert-track track)))))
;;; --------------------------------------------------------
;;; Entry