path: root/apps/playlist_viewer.c
AgeCommit message (Collapse)AuthorFilesLines
2020-07-22keyboard add ability to specify temporary custom layoutsWilliam Wilgus1-1/+1
rb core allows you to load custom keyboard layouts this patch adds the ability to load a keyboard layout in a buffer the custom layout is temporary and does not overwrite the current layout use like so: unsigned short kbd[64]; unsigned short *kbd_p = kbd; if (!kbd_create_layout("ABCD1234\n", kbd, sizeof(kbd))) kbd_p = NULL; rb->kbd_input(buf,sizeof(buf), kbd_p); Change-Id: I7be2bd4a1b4797a147fa70228a9749dc56ac052a
2020-05-20Playlist Viewer Fix FS#13197William Wilgus1-3/+8
While playing a track the playlist viewer may not have a big enough temporary buffer to load and display 'max_files_in_playlist' entries This patch attempts to load as many entries as possible If tracks were already playing (dynamic playlist or otherwise) The original code only gave half the plugin buffer to a playlist loaded from file On some targets half the plugin buffer is not enough to load all entries… Now we attempt to get as many entries possible while at least leaving a small buffer (MAX_PATH) for the name buffer Change-Id: Ic06eaabc4e2550f076d625957d6d073790852743
2018-12-15FS#6323: Speech for ID3 viewer, playlist catalog and playlist viewerSolomon Peachy1-21/+52
Modified from original ticket, Taken from Igor Poretsky's tree, and further modified by myself to incorporate feedback. Change-Id: Ibc2180e52af76890b1448d23f79386fd0f88f709
2015-04-19Don't shorten the playlist on shuffle. Fixes FS#13040Thomas White1-4/+5
Change-Id: Ia482ac8248d831a5364ec7bf4d2ccb7b361d2f05
2014-03-10Implement time-based resume and playback start.Michael Sevakis1-4/+6
This complements offset-based resume and playback start funcionality. The implementation is global on both HWCODEC and SWCODEC. Basically, if either the specified elapsed or offset are non-zero, it indicates a mid-track resume. To resume by time only, set elapsed to nonzero and offset to zero. To resume by offset only, set offset to nonzero and elapsed to zero. Which one the codec uses and which has priority is up to the codec; however, using an elapsed time covers more cases: * Codecs not able to use an offset such as VGM or other atomic formats * Starting playback at a nonzero elapsed time from a source that contains no offset, such as a cuesheet The change re-versions pretty much everything from tagcache to nvram. Change-Id: Ic7aebb24e99a03ae99585c5e236eba960d163f38 Reviewed-on: Reviewed-by: Michael Sevakis <> Tested: Michael Sevakis <>
2014-01-11playlist_viewer: Reset icon callback after leaving the playlist viewer settings.Thomas Martitz1-0/+5
This fixes that the playlist viewer still shows the icons after changing the playlist viewer specific show_icons value until re-opened. Change-Id: I42f287bcf02b27f0255dc157560c2e6575307eb6
2014-01-11playlist_viewer: Resurrect playlist viewer settings submenu in the playlist ↵Thomas Martitz1-2/+8
viewer context menu. This was lost in 97a4c1ef (svn r30177) for unkown reason but the manual still mentions this item, so I assume it was an accident. It doesn't hurt anyway. Fixes FS#12930. Change-Id: I2f5cd81913ec7bb911d1117e50c010a5c1b89b52
2012-07-19Fixing data abort (pc in strchr). when scrolling a big playlist very fast.Purdea Andrei1-5/+41
Change-Id: Ibe00a11592a18d320682cce755e48ce701ff5b4a Reviewed-on: Reviewed-by: Thomas Martitz <> Tested-by: Thomas Martitz <>
2011-12-14FS#12378 : Remove various unused code, and comment out some unused code and ↵Boris Gjenero1-11/+0
data for reference or future use. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-09-17Add an option to shuffle the playlist in the playlist viewerJonathan Gordon1-1/+6
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-08-14GSoC/Buflib: Replace all direct accesses to audiobuf with buffer API functions.Thomas Martitz1-3/+0
Namely, introduce buffer_get_buffer() and buffer_release_buffer(). buffer_get_buffer() aquires all available and grabs a lock, attempting to call buffer_alloc() or buffer_get_buffer() while this lock is locked will cause a panicf() (doesn't actually happen, but is for debugging purpose). buffer_release_buffer() unlocks that lock and can additionally increment the audiobuf buffer to make an allocation. Pass 0 to only unlock if buffer was used temporarily only. buffer_available() is a replacement function to query audiobuflen, i.e. what's left in the buffer. Buffer init is moved up in the init chain and handles ipodvideo64mb internally. Further changes happened to mp3data.c and talk.c as to not call the above API functions, but get the buffer from callers. The caller is the audio system which has the buffer lock while mp3data.c and talk mess with the buffer. mpeg.c now implements some buffer related functions of playback.h, especially audio_get_buffer(), allowing to reduce #ifdef hell a tiny bit. audiobuf and audiobufend are local to buffer.c now. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-08-07%cs (current screen) changes:Jonathan Gordon1-0/+2
* Every top level menu item now has a different screen number * Playlist viewer and Playlist Catalogue browsers no longer share the same number git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-08-01revert r30226, which is apparently broken.Frank Gevaerts1-1/+1
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-07-31Reload the current playlist after reboot even if it has ended. (FS#11644)Frank Gevaerts1-1/+1
This is done to make reboot more transparent. If a playlist has ended, there should be no difference between the player doing nothing for ten minutes and the player shutting down after the idle timeout and being restarted. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-07-21Fix FS#8656 - Error saving non-current playlist fileJonathan Gordon1-0/+8
Use the plugin buffer to save the playlist copy if there isnt enough buffer already allocated to the inram copy of the playlist git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-07-20s/Playlist/Current Playlist/ in the playlist viewer context menu.Jonathan Gordon1-1/+1
This menu needs to be changed to a proper menu so the icons dont suck git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-07-20FS#11808 - Major playlist handling changes (on disk playlists)Jonathan Gordon1-33/+38
* Playlists are treated similar to directories in the browser, they now open in the viewer when selected instead of automatically starting the playlist. * Make the "Playlists" main menu item useful, it now displays the playlist catalog (and has been renamed accordingly) * Default to storing playlists in the catalog * Add a UI to move the catalog directory (other minor stuff too) git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-04-08Whitespace and cosmetics consistency cleanup in playlist_viewer.c, no ↵Nils Wallménius1-65/+66
functional changes. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2011-04-08Voice filenames in the playlist viewer, closes FS#11951Nils Wallménius1-0/+30
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-11-23Playlist viewer: Fix regression introduced by r28138 which made some buttons ↵Thomas Martitz1-1/+1
not work in the playlist viewer. Fixes FS#11772. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-10-02Playlist viewer: Fix off-by-one when moving tracks caused by r28131.Thomas Martitz1-3/+5
The callbacks for the list code need the current item for rendering the moving track, which is not known until after the first draw. Hence the first draw is off. A second one is needed. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-09-21Bad copy&paste.Thomas Martitz1-1/+1
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-09-21Use convenience function.Thomas Martitz1-7/+4
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-09-20Fix a bug in playlist viewer's list handling, causing superfluous redraws andThomas Martitz1-15/+20
potentially leading to the wrong track being selected. The playlist viewer should perform a bit better now. I always felt it was slower than the otehr lists. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-05-06Move c/h files implementing/defining standard library stuff into a new libc ↵Thomas Martitz1-1/+0
directory, also standard'ify some parts of the code base (almost entirely #include fixes). This is to a) to cleanup firmware/common and firmware/include a bit, but also b) for Rockbox as an application which should use the host system's c library and headers, separating makes it easy to exclude our files from the build. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2010-02-20Playlist Viewer Changes to bring consistency:Thomas Martitz1-19/+13
- combine its two context menus to one and - make the ACTION_STD_MENU go to the main menu as it does in all other screens - call playlist_viewer() via root_menu to reduce call depth and to be consistent with other screens (and for the above changes to be more flexible w.r.t to the following screen) git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-12-24Accept FS#8321 by Lee Kang HyukJonathan Gordon1-1/+1
something about the wrong track being selected with a long playlist and playing the last song.. i dunno... its important to set the title of the lists before setting the selection anyway git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-11-25Take out that code from the dynamic playlist viewer that aborts track ↵Dave Hooper1-3/+1
move-in-progress on playlist change .. based on assumption it doesn't do anything other than cause FS#10395 git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-08-20Make the formatter functions used by the settings return a pointer to avoid ↵Nils Wallménius1-7/+7
usless copying of lang strings, this brought with it a long chain of const correctness and a few random cleanups git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-08-12Make kbd_input() show a cancel splash to indicate user abort better and for ↵Thomas Martitz1-1/+1
better consistency all over the place. Change checking for its return value (style-wise) at some places too. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-07-11Fix type mismatch warnings and errors exposed when building with EABI toolchain.Andrew Mahone1-1/+2
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-07-07Fix bug introduced in r21616 (my bad)- playlist moving array could show in ↵Dave Hooper1-0/+5
playlist viewer even when track not being moved git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-07-02Commit patch in FS#7967 by Vuong Minh Hiep (with some small changes to ↵Dave Hooper1-24/+29
variable names for consistency) - separately keep track of viewer-index and playlist-index of moving tracks, so that viewer correctly shows which track is moving when playlist is shuffled, and correctly moves the track you tell it to git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-07-02Fix playlist viewer behaviour when deleting tracks (one ret had missed being ↵Dave Hooper1-1/+9
changed to ret_val). FIx playlist viewer behaviour when deleting the only remaining track in playlist (i.e. when audio stops, prevent resume playback also) git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-05-17Fix duplicate #includesBertrik Sikken1-1/+0
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-05-09Remove unneeded #include "backdrop.h"Bertrik Sikken1-1/+0
Remove unneeded #include "statusbar.h" git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2009-03-08Clean up some #includesBertrik Sikken1-1/+0
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-12-31Decouple the statusbar drawing from the rest of the screen drawing. it is ↵Jonathan Gordon1-5/+0
not drawn roughly 4x per second automatically. viewport_Set_defaults() will setup the given viewport with the correct "full screen" dimensions (so start at 0,0 if statusbars are disabled or 0,8 if they are enabled.) All screens should keep the statusbar enabled, but if you really want to ignore the user setting you can disbaled it with viewportmanager_set_statusbar(false). This commit also includes some menu/list viewport cleanups from kugel in FS#9603 git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-10-10Search In PlaylistNils Wallménius1-15/+26
* Add a title to the list of search results. * Fix drawing of the statusbar. * Avoid splashing in every iteration of the search loop if no new hits, gives about 10x speedup on h300 when searching for a string that gives 30 hits in a playlist of 3000 tracks. * Boost cpu when searching, ~doubles the search speed. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-09-29Fix FS#9418 'Player unresponsive while searching playlist with directory ↵Nils Wallménius1-0/+1
cache enabled' git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-09-07Change screens memebers char_width, char_height and nb_lines to functions ↵Peter D'Hoye1-3/+3
returning a calculated value. Fixes FS #9361 because the values were calculated based on sysfont, not the user selected font. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-08-15FS#9281 Rename of splash functions.Nils Wallménius1-4/+4
* Remove gui_splash() * Rename gui_syncsplash() to splashf() and remove its voice capabilities. * Rename the internal splash() to splash_internal() and introduce an externally visible splash() that handles simple splashing without printf functionality e.g. splash(HZ, ID2P(LANG_FOO)); or splash(HZ, "foo"); if a LANG_* id is passed it will be voiced. * Adjust all places that called gui_syncsplash() to use the correct variant from above. * Export both new functions to plugins and adjust places calling rb->splash() to use the correct variant so that we now have naming consistency between the core and plugins. * Fix one latent bug that would cause my sim to crash with the above changes and correct P2STR and P2ID macros, thanks to pondlife. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-06-28Updated our source code header to explicitly mention that we are GPL v2 orDaniel Stenberg1-2/+4
later. We still need to hunt down snippets used that are not. 1324 modified files... git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-05-12Const police raid.Steve Bavin1-4/+5
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-05-04use the playlist catalog code to generate the playlists under Playlist > ↵Jonathan Gordon1-1/+1
Create playlist git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-04-09Slight readability improvementsNils Wallménius1-5/+13
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-04-09Pass the buffer length to the list_get_name callback functions instead of ↵Nils Wallménius1-5/+10
using hardcoded MAX_PATH git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2008-03-26the menu and list now accepts a parent viewport to draw in (and the menu can ↵Jonathan Gordon1-4/+5
be told to not show status/button bars). This lays the groundwork to fix colour problems with plugin menus (see star.c for an example.) This hopefully fixes some button bar issues as well as theme problems. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2007-12-15Patch "Remain in PLViewer when move_track is canceled", by Lee Kang Hyuk. ↵Antoine Cellerier1-1/+11
Closes FS#8322. git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657
2007-11-18Use the strrsplt function in one more placeNils Wallménius1-4/+1
git-svn-id: svn:// a1c6a512-1295-4272-9138-f99709370657