Commit graph

16721 commits

Author SHA1 Message Date
William Wilgus
822b16b1c6 debug_menu dbg_buffering_thread show more on tiny screens
I think the clipzip has the smallest screen at 96
might need to be enabled for LCD_WIDTH <=128 too

remove scrolling thread info for larger screens

Change-Id: Ic98c9fc0b53f79e90776c13429194f9c37c1d48b
2022-03-22 17:55:23 -04:00
William Wilgus
7910f4a7aa debug_menu cleanup/optimize some common format strings
Change-Id: I84b070f8ea264ea64bddd82f9849ec20c72a4863
2022-03-22 16:16:11 -04:00
William Wilgus
61bc7b91bc tagcache.c remove 16-bit compression for add_uniqbuf
apparently there are tags such as year or genre that are indexed 1 byte
apart, as much as I like the idea of this I cannot come up with a way
to reliably denote 2 16 bit entries from a single 32 bit entry without
losing data or adding bookkeeping which would likely make it pointless

Change-Id: I8a9908575700cab9506c36f5422222145557fa6b
2022-03-22 00:22:42 -04:00
William Wilgus
64c577a0c5 filetree.c cleanup
just a little cleanup of ft file filtering code

store result of filter mask to a local var

put skin apply code in its own function

Change-Id: Ib899608f64e36346b9bde07caa5d5ac29de05af9
2022-03-21 08:14:30 -04:00
William Wilgus
08b42791ff tag_cache.c optimize str_begins_ends_oneof
the function is shared

Change-Id: I362a75ea5a39690647df4f421d9429ef2114ef02
2022-03-19 03:30:54 -04:00
William Wilgus
ddbca125a6 tagtree/tagcache add new clause operators begins/ends _oneof
new operators @^, @$
begins_oneof and ends_oneof

albumartist @^ "L|The L"
Led Zeppelin, The look

albumartist @$ "girls|Boys"
spice girls, beasty boys

Change-Id: I26ce3d8155d970a55e003f74e2f9478db76204f1
2022-03-19 02:24:14 -04:00
William Wilgus
0f2d623216 tagcache add logging option for clause matching #2
Change-Id: Ideaa89a6fb227ecc8a4a107dced98f85b6b40a4f
2022-03-19 02:11:57 -04:00
William Wilgus
a56975af6c tagcache add logging option for clause mtching
Change-Id: I5099287398b448d2f44283419395ab8919d6019c
2022-03-19 01:59:07 -04:00
William Wilgus
a5e684c894 BUGFIX root_menu.c
Change-Id: Ie6268c63f5ed5197d2da678851b4bfdf7764252c
2022-03-18 19:45:01 -04:00
William Wilgus
b31444261e [COV] cuesheet.c var line could be uninitialized
Change-Id: Id753ecc28f4029e05032be0c0ac6ecd27e9e370f
2022-03-18 18:57:55 -04:00
William Wilgus
99f8457279 cuesheet, fix dumb typo
Change-Id: I17aefb0b507898819f9f6d369d986205c6a59c9d
2022-03-18 17:34:11 -04:00
William Wilgus
a13ae2afd5 [COV] folder_select buffer overrun
Change-Id: I441e1fa13d3832b3b12e3f46f35ef63fb3c1de02
2022-03-18 08:59:32 -04:00
Aidan MacDonald
b309fae2bc touchscreen: fix quickscreen
Looks like I made a mistake testing this originally because there's
no way this would've worked.

Change-Id: I89dc0d831e381eb957cf6e1a801236b5cd829efa
2022-03-16 19:57:28 -04:00
William Wilgus
b3e0d18f7d skin_engine.c settings_apply_skins cleanup
just some cleanup and removal of ifdefs in favor of dummy functions

Change-Id: I03a1d351344afcc428dedb67aab915184f99bd23
2022-03-15 20:17:11 -04:00
William Wilgus
20b9ce5497 debug_menu make scrolling manual for OS Threads item
the automatic scrolling is not very nice to try and read instead use
OK button to advance and long press std ok to reset to beginning
(or scroll up and down)

Change-Id: I964ccefcd3c16836cc92f52247d7b8e65c6d627b
2022-03-14 20:53:45 -04:00
William Wilgus
9b4e784560 BUGFIX string_option parsers
fix bugs introduced in the switch over to using string_option
instead of if else strcmp trees,
embedded album art should work again
skin parser had an error for 'noborder' and 'nobar'

Change-Id: I957d81e5fa8467b33bbd93d63c4428c36100acca
2022-03-14 17:23:18 -04:00
William Wilgus
6dcbf7ff77 debug_menu scroll os stack screen
the os threads items update too quick to see them scroll

implement a simple scroller

Change-Id: I1161dec1b528c9b96b31eacd85c1ec2420cac61d
2022-03-14 02:42:02 -04:00
William Wilgus
6d122e3932 cuesheet, cleanup tag code with strncmp
Change-Id: I97076266103d20e59537e4e0959a70cc12b207f6
2022-03-13 17:11:50 -04:00
William Wilgus
2352cef6d0 replace more strcmp if then trees with string_option()
1

Change-Id: Ic89bbb2ab41068d09c7bd9caa5ba7f38749b9084
2022-03-13 14:31:02 -04:00
William Wilgus
77e4dd81f5 option_string clean-up and consolidate with metadata_common
Change-Id: I2649f6af37bd871fb8f181ae2f716ff0bcf1f65c
2022-03-13 10:55:47 -04:00
William Wilgus
eb86ee296a skin_parser.c fix red stupid typo
Change-Id: If4830afc84b32e79ec5aef7add8574485c11af3c
2022-03-13 04:51:16 -04:00
William Wilgus
3f2ad8bf2b skin_parser.c fix red
Change-Id: If093ad790f63d39855bf3253ae7a6c11afcc1a96
2022-03-13 04:22:05 -04:00
William Wilgus
74df3ba2d8 add function string_option to misc.c use in skin_parser.c
function string_option allows a string to be found in a
supplied list of options

Change-Id: If9134090406b74ab11f4ef9ed6517a4b99b9d73e
2022-03-13 03:45:00 -04:00
William Wilgus
eecf840989 playlist.c fix red for non-DIRCACHE targets
Change-Id: Id02f67dee6f40a80c832dea785f56f32885a5528
2022-03-11 22:52:02 -05:00
William Wilgus
a59b3c5d11 playlist_resume, wait for dircache to complete before loading songs
with root redirect and even relative paths eventually we need the dircache
to get files from the disk

Change-Id: Ia443f473f09dd534674d5fdb71251214ce01eed7
2022-03-11 22:30:39 -05:00
William Wilgus
95af36d0dd playlist.c fix red for non multivolume targets
Change-Id: Ic0fdb325bc9c8d886c7627679fb2d02521400da7
2022-03-11 20:05:14 -05:00
William Wilgus
eb32238b22 playlist.c use basename for playlist_get_filename_crc32
strip the vol and use the relative portion

Change-Id: I6259343e63a84f0ab97bd6f491de09320d74eac4
2022-03-11 19:45:58 -05:00
William Wilgus
359c66982f playback.c use file_exists rather than open to check for bad files
the worst case is really slow for open

Change-Id: Ifcfe366ad9bee7ff43a0572e52f15b5c6f608288
2022-03-11 19:45:58 -05:00
Aidan MacDonald
7fa48faeb5 multiboot: Refactor duplicated functions to a separate file
The implementation of write_bootdata() and get_redirect_dir() was
copied verbatim in two different places, obviously a bad thing for
maintainability. This moves them to a new file multiboot.c as they
are only used for multiboot.

Change-Id: Id0279216e4dd019f8bf612a81d3835eff010e506
2022-03-11 10:58:20 -05:00
William Wilgus
355553baf4 playlist_resume, fix control fd, add some error info
I ocassionally see Playlist Invalid messages but which part is failing?
eventually it works so its probably a race

Change-Id: Ib2b09ab13ce09a55130430a2e94bc0498443b6ec
2022-03-11 09:40:31 -05:00
William Wilgus
a8b997e4e9 skinparser cleanup, optimize
hash clause strings for =, ==, !=, <, > <=, >=
store result of get_param() where possible

Change-Id: Ia5a4dbf613d6ec9e21546fa0c6a8de28eb7aa347
2022-03-08 16:51:04 -05:00
William Wilgus
19d95d7b56 keyremap add plain text import and export
allows users to edit and view keymaps in a text editor
(parser requires one entry per line (LF or CRLF work as line endings)

allow naming of files on save

Change-Id: Id6627171eb96210b2deeef8d15bab3f8d1e0ab3f
2022-03-06 17:00:27 -05:00
William Wilgus
bc3fa53937 Sansa Multiboot Root Redirect Enhance + bug fix
filename buffer was too small to retrieve redirect path

if redirected to sd root remove <SD1> as it is redundant

Change-Id: I1326601f1ba4a18d6bc173798759eb762b55528c
2022-03-06 16:42:26 -05:00
William Wilgus
c9857098ac Multiboot Firmware Root Redirect - WIP
Loads external drive into root namespace
Root Redirects can now be put into different folders
For instance placing '/_test' into SD1/rockbox_main.<playername>
will redirect to /<1>/_test/.rockbox
Debug menu>Bootdata now has root directory listed in addition to RAW Bootdata

Redirect root work from Michael Sevakis g#1556, RESTORED -> g#4256

Change-Id: Ia97cf50ff5f5b440877f9c005da6f12c53af931e
2022-03-03 22:08:28 -05:00
William Wilgus
f88ea12bac tagcache compress uniqbuf 2 16-bit indices occupy a single 32 bit slot
a lot of space is wasted when file indices less than 65535
entries should be more than 1 byte apart so use the LSB as a flag
when indices are > 65535 set flag to 0 and proceed as before

explicitly mark uniqbuf as 32bit

Change-Id: I54e06c152c369eb6c0322186fe2c1e9a1e6d940d
2022-03-02 20:22:49 -05:00
William Wilgus
045f52d475 tagtree.c optmize clause operator parsing
makes WS after a clause conditional optional

Change-Id: I335b5381fb788c19130aa8d57dfb18bb43a07c18
2022-02-28 06:35:11 -05:00
William Wilgus
1bcb1e39ee tagcache, coverity cleanup, Add TAGS_ALL_COUNT
Change-Id: Ia880c921a00b603aa4ba81b0c0670ed00491e41a
2022-02-27 11:01:24 -05:00
William Wilgus
6b360d8b04 action.c keyremap clean-up add logf to core_keymap.c
move the remap out of the loop and eliminate a status flag

Change-Id: I9ab841037a8ea7dff736b452ff55e8242084af82
2022-02-26 00:40:42 -05:00
William Wilgus
887249671c TagTree Show file name for tag_title [UNTAGGED]
fallback to filename as [UNTAGGED] is a terrible way to browse titles

Change-Id: Ifcdc4c27562339b8a916313fb946c88c4eba3b5a
2022-02-25 22:54:47 -05:00
William Wilgus
836616b937 Tagcache Don't create filters when parsing a logical OR
if possible search clauses are converted to filters

once a logical OR is added to the mix (CLAUSE1|CLAUSE2 & CLAUS3))
if CLAUSE1,2 are database non-numeric tags they get made into filters
but the logical OR gets carried to the next CLAUSE

Rather than trying to figure this out just keep all clauses around a logical OR

Change-Id: I03e064e7f897033c5d47d78a1d34238217cde485
2022-02-25 22:04:49 -05:00
William Wilgus
bba0564ec1 keyremap plugin use yes_no prompts, bugfix
use the supplied yes_no dialogs for file delete, key reset, save prompt

return to root menu automatically after loading a file

fix bug where deleting the last file in the list exited the menu

Change-Id: Ib98f6b200b9dee3e4350ad4d7ef80bbb95c77481
2022-02-24 00:26:40 -05:00
William Wilgus
295ec3790d Core Keyremap Allow setting keymap from plugin
Allow setting and removing keyremap on the fly

It was pretty annoying trying to work out a keyremap with a restart
required to set the remap and was quite annoying when I was no
longer able to navigate to the plugin or filebrowser due to setting
the wrong remap

now you can try out a keymap and if it doesn't work a restart will
sort things out

Change-Id: I848fb3bd759f9684ac2497324a371f92b7464f7b
2022-02-23 21:38:27 -05:00
William Wilgus
f7bb9e2167 Add custom action mapping to core
results of an idea I discussed in IRC

changed the way the lookup in the remap file works..

 entries consist of 3 int [action, button, prebtn]
 context look up table is at the beginning
 action_code contains the (context | CONTEXT_REMAPPED)
 button_code contains the index of the first remapped action for the matched context
 [0] CORE_CONTEXT_REMAP(ctx1) offset1=(3), count=(1)
 [1] CORE_CONTEXT_REMAP(ctx2, offset2=(5), count=(1)
 [2] sentinel, 0, 0
 [3] act0, btn, 0
 [4] sentinel 0, 0
 [5] act1, btn, 0
 [6] sentinel, 0, 0

 Note:
 last entry of each group is always the sentinel [CONTEXT_STOPSEARCHING, BUTTON_NONE, BUTTON_NONE]
 contexts must match exactly -- re-mapped contexts run before the built in w/ fall through contexts
 ie. you can't remap std_context and expect it to match std_context actions from the WPS context.

-- Done --

Code for reading core remap entries

-- Done --

import of core remap entires from disk
-- Done --

plugin to set new key mapping (the hard part)

The plugin is started and FULLY functional
you can add actions and contexts
you can change context, action, button, prebtn
delete keymap files
load keymapfiles
save user keymaps
test keymaps before applying them
loading keymaps to core still requires restart
-----------------------------------------------------------------------------------------------

Change-Id: Ib8b88c5ae91af4d540e1829de5db32669cd68203
2022-02-23 08:47:12 -05:00
Solomon Peachy
7952687185 FS#13337: Updated Slovak translation (Matej Golian)
Change-Id: I067c5a8e26b44def88fa60b38aabd1d014555e23
2022-02-22 11:15:02 -05:00
Aidan MacDonald
e8faf2f2ad buflib: add a common dummy callbacks struct & use it
There are various allocations that can't be moved or shrunk.
Provide a global callback struct for this use case instead of
making each caller declare its own dummy struct.

Also fixed ROLO and x1000 installer code which incorrectly
used movable allocations.

Change-Id: I00088396b9826e02e69a4a33477fe1a7816374f1
2022-02-12 10:24:32 -05:00
Wolfram Sang
95dfc489b5 sync clock with RDS time
Tested with my SansaClip+. I don't think this will need extra battery
but let me know if I am wrong.

Change-Id: I287dae134113e0f8a138af68f5087b8ea45b0f4c
2022-02-07 22:04:10 +01:00
Christian Soffke
8d453ae9c3 Fix glitches with custom list title viewports
Elements were not being drawn correctly or
title text appeared delayed in several places
when using themes with a custom viewport
for list titles.

E.g.:
- after deleting a shortcut
- when returning from a warning screen in
Playlist Viewer
- returning to some Settings screens
- in "Playing time" screen

Change-Id: I8ab07a31d4b6f290e089ecd7857f43ec195a06e0
2022-02-06 11:20:34 -05:00
Solomon Peachy
04cbb3c7e4 misc: Add 'mpga' as a valid file extension
Some podcasts use this, apparently.

Change-Id: I24f372ed760f15e204dba3a99552ad3b6a051515
2022-02-01 13:23:39 -05:00
Christian Soffke
fb91184c4f PictureFlow: Fix broken (iPod) keymap
I must have only tested de8ee6c9e9 using my
custom iPod keymap. Re-mapping the "Left"
and "Right" buttons in this context badly breaks
existing behavior in Pictureflow when using
Rockbox's default iPod keymap.

Change-Id: I2aff6297d7e229a056383afe6074c41829b38e2d
2022-01-30 16:36:07 -05:00
Solomon Peachy
e91e8439ca FS#13335: Updated Polish translation (Adam Rak)
Change-Id: I6288e6c64d82cc737c5ec1dd3651aa0793894d29
2022-01-30 12:15:51 -05:00