HydrogenAudio

Hosted Forums => foobar2000 => 3rd Party Plugins - (fb2k) => Topic started by: kerpondile on 2011-01-11 06:34:35

Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-01-11 06:34:35
foo_playlisthistory enables playlist history in foobar2000, similar to page history in browsers.

The component watches activated playlists and provides the user back and next buttons to navigate the playlist history.
Two commands are provided under the View/Recently activated playlists: Previous playlist and Next playlist.

From 0.1.4 onwards the component includes Restore last removed playlist command in the Edit menu.

Newest version: 0.1.6 / 2011-04-05

Requires foobar 1.1->

For more information, please see the Wiki page (http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Components/Playlist_History_(foo_playlisthistory)).

Links:
Download the latest version: Here (http://www.foobar2000.org/components/view/foo_playlisthistory)
Source: Github (https://github.com/ssalonen/foo_playlisthistory/).
Wiki: Wiki page (http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Components/Playlist_History_(foo_playlisthistory)).


Please add any comments, I appreciate them!


Sami Salonen
Title: Playlist History (foo_playlisthistory)
Post by: Falstaff on 2011-01-11 16:37:26
Thanx for sharing this, i'll test this new component asap
Title: Playlist History (foo_playlisthistory)
Post by: Robertina on 2011-01-11 17:45:08
Thank you very much (http://www.hydrogenaudio.org/forums/index.php?showtopic=77808), kerpondile !

Robertina.
Title: Playlist History (foo_playlisthistory)
Post by: matav on 2011-01-11 19:14:29
nice component but when i heard the name i had a different idea.
this provides a shortcut to focus to the previous playlist that was played.
kinda handy when you have many playlists.
but in the event of a playlist being replaced or deleted, it can't undo those changes.

could you possible make the component like the winamp plugin "Playlist Undo (http://forums.winamp.com/showthread.php?s=&threadid=226331)"?
that was pretty handy and i have been missing that in foobar.
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-01-12 09:49:12
@matav Yes, the component name might be a bit misleading but it will have to do for now. The playlist undo seems like an interesting feature but for now I'm not going to implement it. I recommend to look for foo_jesus (http://www.hydrogenaudio.org/forums/index.php?showtopic=68528) which can automatically backup playlists (among other things). I know it's not the same thing but at least it might help in situations where you have accidentally removed a playlist.

Also note that you can recover replaced playlists using the 'standard' playlist undo functionality (Edit/Undo).

Actually, I just noticed that you can recover removed playlists using the standard "Playlist Manager" (DUI element). After deleting a playlist you can right-click the element and choose "Restore.../Name of the playlist". Unfortunately, it seems that this functionality is not available to keyboard shortcuts (nor there is "restore last removed playlist" command).


@all:
I'm going to bring 'after delete activate last used playlist' feature to the next version (first proposed in the thread linked by Robertina).
EDIT: New version released.


Thanks to all for your feedback, it's nice to hear that people find this useful!
Title: Playlist History (foo_playlisthistory)
Post by: foosion on 2011-01-12 12:32:55
Actually, I just noticed that you can recover removed playlists using the standard "Playlist Manager" (DUI element). After deleting a playlist you can right-click the element and choose "Restore.../Name of the playlist". Unfortunately, it seems that this functionality is not available to keyboard shortcuts (nor there is "restore last removed playlist" command).
The functionality in the Default UI's Playlist Manager is backed by the core (specifically playlist_manager_v3 (http://foosion.foobar2000.org/doxygen/latest/classplaylist__manager__v3.html)), so it is possible to provide other front ends.
Title: Playlist History (foo_playlisthistory)
Post by: matav on 2011-01-13 07:58:37
I recommend to look for foo_jesus which can automatically backup playlists (among other things). I know it's not the same thing but at least it might help in situations where you have accidentally removed a playlist.
yes, have used foo_jesus. stopped recently. it always hangs my foobar for a second or two and there was no point increasing the time between the previous and next backup.

Also note that you can recover replaced playlists using the 'standard' playlist undo functionality (Edit/Undo).
noted

Actually, I just noticed that you can recover removed playlists using the standard "Playlist Manager" (DUI element). After deleting a playlist you can right-click the element and choose "Restore.../Name of the playlist".
this can be done even in CUI.

i realized that since foobar is playlist oriented, one would generally make a new playlist instead of modifying an existing one. So, this does not create the same problem as winamp where the one and only playlist being deleted or modified would lead to frustration.
Thus, in foobar, it's not much of a playlist undo issue.
Just sometimes, when i play songs in a random order or simply click the random playback button and i want to go back to the previous track, i have to go through the list and rely on my memory but sometimes it's not feasible.

> i could randomize the list and play it normally.
> i could even use foo_np_simple to log the names of the played track to a file which i can later refer to (but this log needs to be flushed regularly)
> i could even go to my last.fm page and check up which tracks have been played recently. But this does not help if i have pressed the random next button within the same splitsecond it started playing (oh! it happens)


i think, a simple place within foobar where this kind of log is easily accessible (something like foo_queuecontents) would be quite helpful.

--
all this was not exactly a request, just my ordeal
Title: Playlist History (foo_playlisthistory)
Post by: Robertina on 2011-01-14 03:10:00
I'm going to bring 'after delete activate last used playlist' feature to the next version (first proposed in the thread linked by Robertina).
EDIT: New version released.

Thank you for adding this feature, Sami. Both functions provided by your component are very helpfully for me.

Quote
Actually, I just noticed that you can recover removed playlists using the standard "Playlist Manager" [...]

In layouts without both playlist tabs (right-clicking on them also provides the restore command) and the Playlist Manager it is a little bit inconvenient to get deleted playlists back. Sometimes I wished there would be a menu entry offering that recovery.

yes, have used foo_jesus. stopped recently. it always hangs my foobar for a second or two and there was no point increasing the time between the previous and next backup.

foo_jesus is highly configurable, including the backup intervals. The settings are in the preferences, section "Advanced" -> "Autosave & Autobackup".
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-01-14 06:45:19
Hi all!

OK, I've released new version with the following changes:
** Playlist removals no longer produce history which contain the same playlist many times in the row.
** 'Restore last removed playlist' command added to Edit menu. Effect is same as the standard 'restore' command when right clicking the playlist manager.

I've also refactored the code a lot, hopefully that does not introduce too many bugs. The most easy way to update the component is using the foobar auto-updater.
Title: Playlist History (foo_playlisthistory)
Post by: Robertina on 2011-01-14 10:24:08
OK, I've released new version with the following changes:

You have obviously within three or four hours rewritten your component, implemented a new function and also updated the WIKI? I am blown.

For someone like me who works with playlists intensively foo_playlisthistory is very labour-saving. So thank you very much again.

Since you added the "Restore last removed playlist" command to the Edit menu it is now even possible to assign a keyboard shortcut to that function.
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-01-18 06:55:17
Thanks! I really appreciate it.

btw, Just released a new version with a fix for a very very rare (should not happen in normal in use, more like theoretical situation) bug. You can update the component using auto-updater.
Title: Playlist History (foo_playlisthistory)
Post by: Jny on 2011-01-18 19:41:57
useful, thanks
Title: Playlist History (foo_playlisthistory)
Post by: fuffi on 2011-02-04 11:16:27
foo_playlisthistory enables playlist history in foobar2000, similar to page history in browsers.
Two commands are provided under the View/Recently activated playlists: Previous playlist and Next playlist.
Please add any comments, I appreciate them!
hello kerpondile,
first, i didnt understand, what that will be useful for and how to use it.

now, that i realized it, and used it some time, i don't want to miss the "history".

i bound "prev" and "next" to keys as read anywhere and it is now very fast to go to the last playlist without searching and clicking in a playlist panel.
great work. thank you :-)
Title: Playlist History (foo_playlisthistory)
Post by: joh316 on 2011-02-13 13:19:07
Hi:
I need a playlist history clear tool(Edit menu) . that likes the Playlist Manager.

with wsh panel mod 1.41, we can manage the playlist,such as remove ,restore ,dup,hide,rename,new autoplaylist(Inc UI).reorder.

however,we can't clear the history after remo......

Thanks!

joh316

Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-02-14 06:44:03
Hi:
I need a playlist history clear tool(Edit menu) . that likes the Playlist Manager.

with wsh panel mod 1.41, we can manage the playlist,such as remove ,restore ,dup,hide,rename,new autoplaylist(Inc UI).reorder.

however,we can't clear the history after remo......

Thanks!

joh316


I'm not sure what you want, could you give me a use case? How would you use this feature?

Thanks.
Title: Playlist History (foo_playlisthistory)
Post by: joh316 on 2011-02-15 02:48:24
ok,
(my poor english)
your program foo_history,can restore last removed playlist in  Edit menu.

pulldown View menu,there is a "playlist manager",this is not a plugin.

it can do almost every thing about playlist.    if  playlists are deleted ,right click the panel,a submenu called "restore" apeared.

is this restore menu,include a "Clear history".  then,restore is unavirable.

So I just want  this"Clear history" add to the "Edit Menu"

////why i want this menu?
as, CUI playlist switch,can'tmake background  transparenty . many user try to use wsh_panel_mode,to design a" playlist switch" ,the wsh_panel_mode author add many functions about  playlist,such as fb.playlistCount,fb.Moveplaylist(a,b)  ..... Howerer,it is difficult to make a function :Clear history.


Thanks
joh316
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-02-15 16:29:12
Now I understand what you mean.

However, I think the feature is something that is not very useful to normal users. I don't understand why would anyone want to remove the "removed playlists history". It's not like they consume a lot of space. And if they want to do it (not very often, I assume?), it perfectly possible using playlist manager.

I think it's wrong to put too much into one component, at least if it's not useful to many users.

Of course, making a component implementing the feature you talked about should be very straightforward. Maybe you could even implement it yourself? I can provide further tips on that if you want. Maybe you event want to make "support library" for your wsh panel functions?
Title: Playlist History (foo_playlisthistory)
Post by: joh316 on 2011-02-16 06:05:12
Sorry,
the" restore" menu also in the end of CUI playlist switcher,if we  do any delete acction.  in this restore menu include a "clear history"
,just likes the playlist manager.

why I need clear instead of restore?
    in CUI or playlist manager,when we restore a removed playlist, foobar will ask us the new name,and always restore to the end of playlist.
I think ,this is not a clever job.
    Now, in wsh pannel, we use Array to manage the playlists, I use hide instead of Remove command, restore = unhide, the advantage is all manager by
array function. eg.  when I hide a playlist at position 4,  unhide it will be at 4 too,  not at  the end. and need't type new name.  so I need't restore command,because I usually  need not  to delete the playlist, only hide them.        If I really decide to delete a  playlist , I wish it be unrecoverable.  when restored, new name maybe  the old one.

Library , I never use this low  efficiency thing, I prefer to  Explorler Tree plugin.
//______
If  possible ,please write a " Edit  / Clear playlist history " only for me first.when I delete a playlist ,I will add Clear playlist history command  under  it.
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-02-16 08:43:04
With "Library" I mean "Software library", that is, the WSH functions you are creating. Now you told me the use case: hiding playlists. However, I still don't understand why you want things to be "unrecoverable".  As far as I understood, the hiding/unhiding would work just fine without clearing the playlist history. You just have to keep information what playlists are really "deleted" and what are "hidden".

Automatically deleting playlist history changes the way foobar functions. I think the approach sounds like a "hack" (that is, non-pretty workaround). It's not nice for the user because after installing the component, the playlist history would clear itself without any user notification (as a side effect). What makes it worse, normally foobar asks for user's confirmation before clearing the "removed playlists history"; now you'd skip the confirmation altogether.

I'm sorry but I don't have time to create another plugin at this moment. But I'm sure you could do it, it's not that hard really. Good place to start is Foosion's site (http://foosion.foobar2000.org/doxygen/latest/) where you can find the API documentation and also guide to set up Visual Studio project settings. SDK also includes component samples.
Title: Playlist History (foo_playlisthistory)
Post by: joh316 on 2011-02-17 05:44:15

Thanks for replying. Maybe I will try SDK, but I think it is too difficult for me.
Title: Playlist History (foo_playlisthistory)
Post by: tg2k3 on 2011-05-03 01:34:33
Finding this component is like god hearing my prayers. Thank you.
Title: Playlist History (foo_playlisthistory)
Post by: kerpondile on 2011-05-04 13:57:01
Updated the component. Basically just rebuilt with the new SDK meaning that you will need at least foobar 1.1.
Title: Playlist History (foo_playlisthistory)
Post by: TakuSkan on 2012-06-03 11:14:32
Is there some simple title formatting using tabs to space out %title% - %artist% - %album% into even columns in a foo_playlisthistory panel?  Don't know there's an obvious solution, or if the panel doesn't allow it.
Title: Playlist History (foo_playlisthistory)
Post by: db1989 on 2012-06-03 11:31:25
How about $tab (http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Title_Formatting_Reference#.24tab.28.29)?
Title: Playlist History (foo_playlisthistory)
Post by: TakuSkan on 2012-06-03 12:26:31
How about $tab (http://wiki.hydrogenaudio.org/index.php?title=Foobar2000:Title_Formatting_Reference#.24tab.28.29)?

Since foo_playlisthistoy isn't a text or word processor, it has no (to my knowledge) preset column fields.  So if you use $tab between the tag values, it will insert a tab, but not at any preset column field positions. So instead of even columns, you just get a set distance between metadata vales that are in a different position in each row.

I'm not familiar enough with FB2K title formatting to know if something like what I'm looking for here can be accomplished.
Title: Playlist History (foo_playlisthistory)
Post by: JisSey on 2012-08-21 09:39:40
Hello

Please, could you tell me how to insert a last.fm toolbar as seen on your screenshot ? Thanks!

(http://wiki.hydrogenaudio.org/images/9/99/Menu.png)
Title: Playlist History (foo_playlisthistory)
Post by: Emerelle on 2012-08-21 13:20:51
Jissey, this seems to be a WSH script panel - the script from Marc2003 called Webbuttons I guess. Look in the thread for WSH script mod help - he offers them there.
Title: Re: Playlist History (foo_playlisthistory)
Post by: zaede on 2018-08-15 13:13:55
I know long time ago....... but

it doesn't seem to work anymore and i used a lot.
Possible to repair or is there a nother way to activate a playlist X via shortcut ?
foobar v 1.4

Thanks for help.
Peter
Title: Re: Playlist History (foo_playlisthistory)
Post by: anamorphic on 2018-08-16 03:17:20
Possible to repair or is there a nother way to activate a playlist X via shortcut ?
You can hold SHIFT and View > Switch to Playlist, to get a specific playlist (available for shortcuts and buttons). There are no handy 'Previous' and 'Next' options on that menu though.

EDIT: The 'Previous' and 'Next' Playlist options are available on the File menu.
Title: Re: Playlist History (foo_playlisthistory)
Post by: zaede on 2018-08-16 06:21:23
It was late last night, i didn't see.
Now i am happy. Thanks a lot !