Commit graph

17845 commits

Author SHA1 Message Date
Christian Soffke
dec8d4101d PictureFlow: Fix some annoyances
- Skip superfluous "Wait" splash before displaying
  index progress

- Display current step that the progress bar pertains to

- Exiting the "Confirm Quit" screen in order to continue
  indexing was *extremely* fiddly because of picked-up
  button events that would often immediately return you
  to the same screen instead of getting you out of it.
  This should behave more sanely now. Plus, you should
  only see the Quit confirmation screen as a result of
  pressing Menu or Cancel now (instead of touching the
  scroll wheel for example).

- PictureFlow was unresponsive while removing duplicates

- A Cancel action initiated by the user isn't treated
  as an error anymore, nor is a message displayed after
  user has already confirmed their intention to quit.

- The plugin doesn't return errors anymore if the user
  has already been presented with an error message, to
  eliminate redundant splashes, delays, and an unwanted
  return to the main menu

Change-Id: I255b8f760ccb0acdfddcacbc7d8a1b17b063e53e
2025-03-09 09:06:42 -04:00
Christian Soffke
7693ecc2a2 tagtree: Improve suggested playlist filename for "special entries"
Make the suggested playlist filename for special
entries such as "[Random]" or "[All Tracks]" a
bit more descriptive, by mentioning the current
table as well, e.g.:

"The Beatles [All Tracks].m3u8", instead of just
"[All Tracks].m3u8"

Change-Id: I43d9386c06081540cdcae715afc0b0351857633d
2025-03-09 09:05:52 -04:00
William Wilgus
10b4cab793 battery_bench export_battery_tables add warnings
moves shutoff and disk safe to end of file

add warning

comment out shutoff and disksafe level as further protection

Change-Id: I1723b2ae6b2bd7fd359dc7dfcc8f1958d97673fc
2025-03-07 13:14:31 -05:00
Solomon Peachy
8ef4f217d4 checkwps: Warn if using SYSFONT in a viewport
Change-Id: Ief69dd489d08af62ed96624dfe504ab5b9f9e6d9
2025-03-07 09:39:53 -05:00
Solomon Peachy
48b5054a7e more red fixes.
Change-Id: I27f0f4e616585608646b832bef7c4b0cfbd08917
2025-03-06 13:45:11 -05:00
William Wilgus
a1fd56ba8e [FixRed] Bootloaders, devices without size_t defined
Change-Id: I452760478ea7324458a05c7af0a88bcbe92def45
2025-03-06 12:39:37 -05:00
William Wilgus
10f8312db4 FS#13538 export and import battery level tables
when battery_bench is run
exports a file in the rockbox directory called 'battery_levels.default'

if the user wants their own levels they can rename the file battery_levels.cfg
and it will be loaded at boot

some minimal error checking is performed prior to using the values

added manual entry

Change-Id: Ia0126faced0c7229fcf8385a1bcb584b5a9dc378
2025-03-06 11:54:21 -05:00
Solomon Peachy
33a011a6a1 FS#13571: Updated Turkish translation (Mustafa YILDIZ)
Change-Id: Iedb6e65e8daec65f74ab3c47466417760de24a38
2025-03-04 17:20:45 -05:00
Solomon Peachy
f3ce792af8 sysfont: Fix buffering debug screen, cube plugin, and vu_meter plugin
Instead of being hardcoded to expect 8px sysfont, make them scale properly

Change-Id: I02cc6cb53eebbd8241a142964bff305a1c5e535a
2025-03-04 13:40:17 -05:00
William Wilgus
d5db4202ab [Bugfix] tree.c tree_get_file_position() case insensitive search
some targets have case sensitive filesystems

Change-Id: I50744b8226318c3dea3db375e545dbd52998544f
2025-03-03 13:15:34 -05:00
William Wilgus
fb96ae2cc9 tree.c small cleanup no functional changes
Change-Id: Icb165ed94f8e1a165f285c7482c46d6e74846d10
2025-03-03 12:58:09 -05:00
William Wilgus
ef03dde011 skin_parser small clean up add percent_parse_param()
consolidate the logic for PERCENT tags to a single function

is_default() check is redundant in parse_albumart_load()
static bool isdefault(struct skin_tag_parameter *param)
{
    return param->type == DEFAULT;
}

Change-Id: I7391224499624db7a95a2630f96e33827d1e7542
2025-03-03 11:44:26 -05:00
William Wilgus
914fcab06a shortcuts.c don't call settings_apply_skins() unless needed
Add F_NEEDAPPLY if F_THEMESETTING requires a call to settings_apply_skins()

Change-Id: Ied1bf7b2c4fb2e07bf1f54076e647bdc0844037a
2025-03-02 23:50:54 -05:00
William Wilgus
81c65536ec [Bugfix] #FS13567 5+ fonts WPS file causes next theme loaded to fail
Investigating this issue I found that when
SBS and WPS share the same fonts the refcount prevents
the soon to be unused font from unloading
by the time the fnt is unloaded its already too late because the WPS
load failed.

What appears to work is freeing the fonts used by the skin items ahead
of time via skin_reset_buffers() in a separate loop instead of in the
loop used to load the skin files

Change-Id: Ib118163185d48b67b7c96e436bfb6fab8db546a9
2025-03-02 14:41:06 -05:00
William Wilgus
dad8f163c3 lastfm_scrobbler fix formatting, progress messages, export mode
make the plugin context aware to allow user to one
click export from a shortcut, basically it checks if its running in the
file browser if elsewhere does auto export

use a buffer for the fixed portion of the scrobble data

add timed_yield to long running operations
add progress bars and messages as scanning for duplicates takes a while
speed up duplicate scanning 4x

1000 tracks processing took ~2 minutes with duplicate scanning down from ~5

previous patch makes playback logging create a new file after 512k
old files renamed playback_0001.log
make scrobbler able to parse these log files

add ability to skip tracks without metadata and count them

Remove duplicates only for resume or remove all duplicates

allow skipping tracks without metadata or save only filename

update manual

Change-Id: I115bcfd3381f5a978252aac1cdfcc080f0797dda
2025-03-01 19:16:46 -05:00
William Wilgus
731f3fd8be Playback logging add Start time and rename when log size exceeds 512k
renames to playback_nnnn.log

you won't get the message when first enabling logging since it
happens at start-up..

Change-Id: I58ca65a48deff7c5bb1f93c3d86d9ee9e19f3f2e
2025-03-01 19:16:46 -05:00
William Wilgus
cebbbb9ea4 make splash_progress lock to screen width on repeated calls
when calling splash, splash_progress repeatedly text rearranges and
the width changes leaving artifacts on the screen from the previously
displayed prompt

save the max width seen between calls to ensure the splash
prompt is never more narrow.

Height could be stored in a
similar manner but I deemed it unnecessary as typically the
text gets longer and the prompt increases in height
while the reflow causes the prompt to get more narrow.

keep track of the current activity and reset the max_width
when activities change (except bootloader)

Change-Id: I3303bd9135ab1d7bcf28bd5c28d0ab5346bf2697
2025-02-28 12:09:55 -05:00
William Wilgus
10923de8fe [BugFix] OpenPlugins wrong plugin lang id
Failing to use ID2P caused the lang id to be off by VIRT_PTR

Change-Id: Ibbabaae6c1fe130af4053ef3ebe2b1aa69530466
2025-02-25 17:59:52 -05:00
Solomon Peachy
dbebbcfed1 Minor mechanical correction for Italian translation
Change-Id: I4b201345c21505b401b8d71170e200b54f5c6a89
2025-02-24 21:55:30 -05:00
Solomon Peachy
77f0591cc1 FS#13570: Updated Italian translation (Alessio Lenzi)
Change-Id: If9c49160e34b5cc85d3864f1d51faf96eb037bfb
2025-02-24 18:24:53 -05:00
William Wilgus
19956a0777 [Bugfix] WPS pause while WPS not active causes display corruption
Discovered this in the sim with car adapter mode: on

when charger gets disconnected the device is paused

if you have a different screen up the scrolling elems
get redrawn incorrectly over the current screen

to fix check the activity is the WPS, FM, or RECORDING  before allowing redraw

Change-Id: Ie3618347fde446fe0b78b9d3c67261ca63ffee1c
2025-02-24 12:16:44 -05:00
Solomon Peachy
4a6b27a712 chessbox: Get rid of strings for level 8/9/10
We've been limited to level 7 since approximately forever, so
there's no point in wasting translation strings on anything higher.

Change-Id: Idee0f1f0aa1b99d9efdcaa34d0d3130a54e1628e
2025-02-21 18:13:00 -05:00
William Wilgus
50da856992 [BugFix] itoa conflicts with mingw rename to itoa_buf
Change-Id: Ife361f2fd8c8946db5bb2e0e58c0981b2ed3c5f3
2025-02-18 10:41:18 -05:00
Solomon Peachy
ee4591d9e7 FS#13565: Updated Serbian translation (Ivan Pešić)
Change-Id: Iea26a845a1d1d1e5a354133f0a5a323a665f5498
2025-02-16 07:59:19 -05:00
Solomon Peachy
9231ec9393 FS#13564 - Update of Chinese-simp translation (王吉)
Change-Id: I1be11b7635b61345c600108496f8596aa6f0091c
2025-02-16 07:53:58 -05:00
William Wilgus
7912afa32f [BugFix] settings.c CRC calculation skipped F_CUSTOM_SETTING
F_CUSTOM_SETTING write to the cfg file they do not however
have a value in the settings struct to check against for the CRC

at best you get the is_changed value but as Chris_S pointed out this
works the first time BUT unless you are changing from DEFAULT to
'is_changed' or back there is nothing different in the CRC and thus
further changes to custom settings do not get saved unless other
settings change the CRC.

Instead we will ask each of the custom settings to write their output
and run the CRC on those values as well and allowing us to check for changes

Change-Id: Ib3e7b621d676be5eb5ddc9eea00c4805292773fb
2025-02-15 12:46:01 -05:00
William Wilgus
5471f58fb1 [Bugfix] set_current_file_ex filebrowser wrong file on resume
can't have it both ways blocking directories from filename
makes shortcut folders browse into the folder but blocks
the folder when the file browser loads it causing you
to be in the wrong folder upon resume

I wanted a way for the user to be able to leave the slash off
so ensure shortcut folders have a trailing slash (on load)

Change-Id: I9ea173a90a8c12291a159e7d30ee1076e0ca5d3e
2025-02-15 02:47:14 -05:00
Paul Sauro
ac03680df3 keyboard.c: Layout dynamically the morse cheat sheet (supports larger sysfonts)
The main usecase of this is so the morse cheat sheet does not look broken (with cut characters) when we are using a different/larger sysfont. All is adjusted automatically thanks to the SYSFONT_WIDTH and SYSFONT_HEIGHT constants.

Long pushs are now represented as vertical long bars, while short pushs are represented into short bars (centered in the middle). The long pushs bars are not larger anymore, so spacing is consistent everytime for all long+short order different combos thus looking cleaner and more readable.

The code was also a bit refactored to be more easily understandable in the future by using clear variable names to describe the magic values.

- Tested with mini2g: no regression, can still show all characters no problem within the limited screen space that is available on this device
- Tested with ipod6g by configuring the same default font as erosq (14-Rockboxmix) which is larger than the default sysfont: looks really good ! Way more readable than before
- Tested with 4gmono: no regression

Change-Id: Ida8b37ac7bd0bb5f0d314b5dea7657aa41bf2650
2025-02-13 20:37:13 -05:00
Solomon Peachy
da9dc33d85 lang: Correct voice string for LANG_FONT_LOAD_ERROR
Cut-paste error that was unfotunately carried forward in translations

Change-Id: If3a61ec3a276873cf3099f27ee7aa64ef6300876
2025-02-13 20:04:42 -05:00
Solomon Peachy
ad556794d2 internals: VIRT_PTR correction for PP SoCs
Accidentally put one too many zeroes in the address, placing it into
(real) IRAM instead of just past the edge of DRAM.

This didn't affect the s3c2440 and imx31, as they didn't have anything
in that typo'd location.

Change-Id: I2a2e3e3e0d1222ccd04901f8a85790cf21f0aac9
2025-02-13 08:37:32 -05:00
William Wilgus
922a2a4f3d tree.c optimize bookmark_play()
optimize the index search loop using mod()
instead of checking index and then scanning we can start at index
and roll over saving a compare in the process

Change-Id: Ie54fbf1ca0131db8914985b654248eeb8d725a82
2025-02-12 02:29:30 -05:00
Solomon Peachy
801260dd79 internals: VIRT_PTR needs to point at an *invalid* unmapped address
As an added bonus, don't allow it to be 0 as that could result in a
nullptr for ID2P(0).

Change-Id: I1d6eed774771790fae49f0e56a2f29351cab8d5c
2025-02-11 12:27:06 -05:00
William Wilgus
1ea5d57303 [BugFix] TagNav Custom Menu Entry Wrong title, crashing menu
Wrong title is due to the VIRT_PTR being 0 so when a NULL
string is passed through P2STR() you get langid(0)
that was 'Yes' now it will be 'Rockbox'

the crashing menu was due to a call to retrieve entries that wasn't guarded
against  getting called on a menu with no entries

g#5911 introduced this path to call custom_action for shuffled track adding

Change-Id: I3918debbe2e79dfc9595df56b05b1ae59ba94317
2025-02-11 01:00:28 -05:00
William Wilgus
d893da1929 tagtree.c get_tag() increase performance
while its not a particularly hot path it still gets called upwards
of 1000x on startup

with a little pre processing we can make it faster than even the
prior version

check first letter before calling function
move strlen check to after the case match

Change-Id: I0108aaf9828501b57b0950fbc24cd478a9eeacc1
2025-02-10 13:12:18 -05:00
Solomon Peachy
8cc937f33a FS#13563: Updated Chinese (Simplified) translation (王吉)
Change-Id: Ied4b8191c1b00b24bfc5678526c004eb6277cd94
2025-02-10 08:52:30 -05:00
Solomon Peachy
0a29f8b452 FS#13562: Updated Korean translation (Hoseok Seo)
Change-Id: I04e4f88598a521882a880a96adc74bc0436cd93a
2025-02-09 17:06:50 -05:00
Solomon Peachy
210b5e602f FS#13561: Update Polish translation (Adam Rak)
Change-Id: I06ce6112825b7fa7c72951431a6ba2562c65e211
2025-02-09 17:05:41 -05:00
William Wilgus
a29af6e7c6 tagtree reduce size of get_tag lookup table
this is not a hot path only runs at start-up and tagnav reload
so speed is not so much of a concern

we can split the data into two separate tables to
remove the padding and allow symbols to be stored in uint8
(highest symbol <128) and do strlen at TOU

use uint16_t for get_clause()

Change-Id: I0f8663d0de9cac102f1d58b43bf200272754c466
2025-02-09 16:39:55 -05:00
Solomon Peachy
bb84e9def5 Update english-us "translation"
Change-Id: Ic9933064de5fc874cbdb395e822336fe623f2845
2025-02-09 08:41:57 -05:00
Solomon Peachy
fa0c81e0e4 french: Fix missing <phrase> syntax for LANG_RESET_EQUALIZER
Change-Id: I3415405e75a63f20a87f46addc6cba99922b3044
2025-02-09 08:33:54 -05:00
Paul Sauro
2e98889be3 tagtree: Special character/Numerical entry: reduce required CPU cycles to improve performance
Change-Id: I3939e417b78e674834af7154c4a1d0565f606aa7
2025-02-08 20:01:45 +01:00
Paul Sauro
d5fc0e4cb3 tagtree: "By First Letter" : fix numerical entry + add a "Special character" entry
- The "Special character" entry will show all special characters (non numerical + non letters)
- The numerical entry was bug, and could show some special characters from the ASCII table. It is now fixed.

Change-Id: I001fb322fab81918996e15e4d0ca6b7c9e5160af
2025-02-08 12:14:32 -05:00
Paul Sauro
2cf6a443b1 tagnavi.config: Add "Album Artists by First Letter"
Add a new entry, it is useful to go this way for large libraries rather than scrolling manually through the whole list

Change-Id: Ia54b613b4a5fa40863ebb176a549287d3a765a56
2025-02-08 12:14:32 -05:00
Paul Sauro
fa5d2f3edf Database view is fully translatable and entries can be voiced.
* All tagnavi.config entries pulled into language files
 * Database viewer looks up LANG_IDs from the entries
 * If we find a match, we can translate and voice these entries
 * Add (disabled) mechanism to allow voicing database metadata

Original patch by Paul Sauro
Modifications by William Wingus
Further modifications by Solomon Peachy

Todo/Problems:

 * Current Tagnavi headers are rather awkward in English
 * Can't voice the "By first letter" alphabetic entries
 * No mechanism for generating talk clips for DB metadata

Change-Id: Ic276ccda1bd8aae550d38be852bae4c6f697cd47
2025-02-08 12:14:32 -05:00
Roman Artiukhin
0847bcc110 metadata: opus, vorbis, speex: support embedded jpeg album art
It includes .opus, .ogg, .oga, .spx files

Change-Id: I3d0ee9806b05911fc8c3ce5cb761de87d4166141
2025-02-08 10:02:21 +02:00
William Wilgus
e09b466554 screen_access add set_drawinfo
Change-Id: I32e4932eb3a6f06d45aff2cd767484d254a1c9ff
2025-02-08 00:49:28 -05:00
Solomon Peachy
f60892e26c FS#13558 - Updated Simplified Chinese Translation (王吉)
Change-Id: Ifaa27865851694cd64593e1adc501fb8c9241f5a
2025-02-03 23:29:52 -05:00
Solomon Peachy
371797cf1f FS#13557 - Updated German translation (Wilfried Winkler)
Change-Id: Ib78162c9ae13397b27b76a69c316b8b7964584c1
2025-02-03 23:28:41 -05:00
William Wilgus
f55fe21f66 add itoa(), replace snprintf("%d") calls
we can save some space and still end up with a 20% faster function

Change-Id: Ia58900122944b8527ef01a673afe18ea794acb41
2025-02-03 01:23:49 -05:00
Solomon Peachy
9e61d53c7c FS#13556: Updated French translation (CHAPUIS Adhemar)
Closing in on that 100% mark!

Change-Id: If27f9820b6d96aabfaa642e3e387cb2704cb5795
2025-02-02 18:30:36 -05:00