emms-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emms-patches] darcs patch: emms-streams: Make hitting RET on a URL do t


From: Michael Olson
Subject: [Emms-patches] darcs patch: emms-streams: Make hitting RET on a URL do the right t...
Date: Sun, 28 May 2006 23:02:05 -0400

Sun May 28 23:00:43 EDT 2006  Michael Olson <address@hidden>
  * emms-streams: Make hitting RET on a URL do the right thing, improve cursor 
movement, and mark the buffer as unmodified after performing a save.
New patches:

[emms-streams: Make hitting RET on a URL do the right thing, improve cursor 
movement, and mark the buffer as unmodified after performing a save.
Michael Olson <address@hidden>**20060529030043] {
hunk ./emms-streams.el 252
-  (let ((buffer (find-file-noselect emms-stream-bookmarks-file)))
-    (set-buffer buffer)
-    (erase-buffer)
-    (prin1 emms-stream-list buffer)
-    (save-buffer)
-    (kill-buffer buffer)))
+  (save-excursion
+    (let ((buffer (find-file-noselect emms-stream-bookmarks-file)))
+      (set-buffer buffer)
+      (erase-buffer)
+      (insert "(")
+      (let ((firstp t))
+        (dolist (stream emms-stream-list)
+          (if (not firstp)
+              (insert "\n ")
+            (setq firstp nil))
+          (prin1 stream buffer)))
+      (insert ")\n")
+      (save-buffer)
+      (kill-buffer buffer)))
+  (set-buffer-modified-p nil))
hunk ./emms-streams.el 364
-  (let* ((line  (get-text-property (point) 'emms-stream))
+  (let* ((line  (or (get-text-property (point) 'emms-stream)
+                    (progn
+                      (goto-char (or (previous-single-property-change
+                                      (point) 'emms-stream)
+                                     (point-min)))
+                      (goto-char (or (previous-single-property-change
+                                      (point) 'emms-stream)
+                                     (point-min)))
+                      (get-text-property (point) 'emms-stream))
+                    (error "No stream found at point")))
hunk ./emms-streams.el 399
-  (forward-line 2))
+  (when (get-text-property (point) 'emms-stream)
+    (goto-char (or (next-single-property-change (point) 'emms-stream)
+                   (point-max))))
+  (goto-char (or (next-single-property-change (point) 'emms-stream)
+                 (point-max)))
+  (forward-line 0))
hunk ./emms-streams.el 408
-  (forward-line -2))
+  (unless (get-text-property (point) 'emms-stream)
+    (goto-char (or (previous-single-property-change (point) 'emms-stream)
+                   (point-min)))
+    (goto-char (or (previous-single-property-change (point) 'emms-stream)
+                   (point-min))))
+  (when (get-text-property (point) 'emms-stream)
+    (goto-char (or (previous-single-property-change (point) 'emms-stream)
+                   (point-min))))
+  (goto-char (or (previous-single-property-change (point) 'emms-stream)
+                 (point-min)))
+  (forward-line 0))
}

Context:

[emms-player-mpd: Use more robust method of detecting whether we need to 
force-feed MusicPD our playlist.
Michael Olson <address@hidden>**20060525014253] 
[emms-playlist-mode: Make "d" kill the entire line.  This seems to be a good 
compromise of those who use C-k and those who want more standard object-killing 
behavior.
foo**20060524200008] 
[emms-player-mpd: When showing the currently-playing song, prepend the name of 
the radio station, if it exists.
foo**20060524195911] 
[emms-player-mpd: Make seek work correctly.
Michael Olson <address@hidden>**20060525033120] 
[emms-player-mpd: Fix bug that caused unconditional reloading of the entire 
MusicPD playlist whenever the track was changed manually.
Michael Olson <address@hidden>**20060524061655] 
[emms-player-mpd: Overhaul for streamlist support, and fix a few miscellaneous 
issues.
Michael Olson <address@hidden>**20060524055707] 
[emms-player-mpd: Add a few checks to make sure that the given buffer exists 
before trying to do anything with it.
Michael Olson <address@hidden>**20060517035419] 
[emms-source-playlist: Do not expand names of files in playlists, as this can 
cause problems with emms-player-mpd in some configurations.
Michael Olson <address@hidden>**20060516081257] 
[emms-playlist-mode: Implement the option (disabled by default) of opening a 
new EMMS buffer for a playlist, when hitting RET on one.
Michael Olson <address@hidden>**20060510040730] 
[emms-playlist-mode.el: Don't put a period after the mode map. This hangs 21.4 
on display.
address@hidden 
[TAG 2.0
address@hidden 
Patch bundle hash:
f5a0b4ac6b7a14e3b528823ad9631b65c9570047

reply via email to

[Prev in Thread] Current Thread [Next in Thread]