diff options
author | Michael Olson <mwolson@gnu.org> | 2006-10-22 20:17:00 +0000 |
---|---|---|
committer | Michael Olson <mwolson@gnu.org> | 2006-10-22 20:17:00 +0000 |
commit | c3e08253a22aaa9ba3eba33178168da689fa87e2 (patch) | |
tree | f5ff1067d7c1a9ab313610b82f35012bc351b986 | |
parent | 80454515b177a5883118586aeea95b9007c84ced (diff) |
emms-playlist-mode: Handle case where selection has not been set but user wants to delete a region
darcs-hash:20061022201724-1bfb2-58bd537d09c2f5bb2d6c70e72ed125488a7b24d8.gz
-rw-r--r-- | emms-playlist-mode.el | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/emms-playlist-mode.el b/emms-playlist-mode.el index bc16701..c41cbe3 100644 --- a/emms-playlist-mode.el +++ b/emms-playlist-mode.el @@ -298,10 +298,11 @@ function switches back to the remembered buffer." (interactive) (emms-with-inhibit-read-only-t ;; Are we killing the playing/selected track? - (when (emms-playlist-mode-between-p - (marker-position emms-playlist-selected-marker) - (region-beginning) - (region-end)) + (when (and (markerp emms-playlist-selected-marker) + (emms-playlist-mode-between-p + (marker-position emms-playlist-selected-marker) + (region-beginning) + (region-end))) (emms-stop) (delete-overlay emms-playlist-mode-selected-overlay) (setq emms-playlist-mode-selected-overlay nil)) |