1
0
Fork 0
forked from len0rd/rockbox
Commit graph

17607 commits

Author SHA1 Message Date
Christian Soffke
75282a1683 Playlist Viewer: Remove forward declarations
Change-Id: I16faf5e43001e139fc8affc942ee8dbf49f99bb1
2024-11-18 06:15:18 +01:00
Christian Soffke
78bea2a7ac playlist: Remove playlist_get_required_bufsz
Change-Id: I00cf26a2502f1b31cab8d896bf8eb1ae2626020a
2024-11-16 12:18:03 -05:00
Christian Soffke
953fcef05e gui: Fix unsuccesful attempt at loading default viewer iconset
The default viewer icons file seems to have
been removed in the rewrite of buildzip.pl
(see commit 66b6fdb).

So, this only worked accidentally, once some
theme put a viewers.bmp file in the icons folder,
potentially leading to confusing behavior.

Deactivating viewer icons (instead of reverting
to some default file) when they are set to "-"
is probably expected behavior at this point.

Change-Id: I5010764676c67592bf20abfb3d0780edb1d555d4
2024-11-16 12:14:00 -05:00
Christian Soffke
ff2f9123f6 gui: splash(-progress): use theme colors, +1px spacing
Change-Id: I5867b1fd3086bda2973f75a3ad1c1223e22dc0ae
2024-11-16 18:10:37 +01:00
Solomon Peachy
15a4eb0422 debug: Correct most of the sector_t printf()s
The 'll' printf modifier is currently broken.  Fortunately all but
one of the uses is printing MB instead of bytes, which means we can
cast the value to a 'unsigned long' without risk of overflow/wraps.

...There's one remaining use ('%llx') which still needs to be sorted
out.

Change-Id: I89f406f6c085be153531d1ec1f2a314ae172b129
2024-11-15 07:28:55 -05:00
Solomon Peachy
461704f803 misc: Fix some compile warnings when logf is enabled
Change-Id: I67b611cbbbe33113853f36da5047ba799f1dda5d
2024-11-12 08:11:18 -05:00
Christian Soffke
cb7b6fd572 skin parser: Fix crash that can occur when same bmp is loaded multiple times
img may have already been loaded, in which case
bm.data will intentionally have been set to NULL
(see NOTE in load_skin_bmp)

Also see commit 01cbb79 and previous fix 35f9a5b

Change-Id: I581ed63836f30a6b669b3d1fd5886fc1b3664386
2024-11-12 13:39:19 +01:00
Christian Soffke
8e2b11cd3c pugins: PictureFlow: Fix album not found
Each artist name is only stored once, regardless of case,
so we have to perform a case-insensitive comparison with
the current artist.

Change-Id: I571c0e49c032a6d5c64f6e3289513ba7fe279cb8
2024-11-12 01:57:42 -05:00
Christian Soffke
9b20f59ac6 plugins: Simple Viewer: Exit when pressing Select, or (on iPods) Menu/Left
Change-Id: I63d9c90f30783115f9fad70dae1818ad90ba79dd
2024-11-12 07:55:48 +01:00
Christian Soffke
c67294913f Fix get_token_value from 7288d9e
Change-Id: I3d1b2fc37c0baa1cb178215889bf91808ba4287f
2024-11-11 08:21:12 +01:00
William Wilgus
27c5db15e3 [Fix Red] #3 cfg_vals missing brace
Change-Id: I76ce21f5109d7ce3ca0d04dcf8f226a3f468ee8c
2024-11-10 23:59:40 -05:00
William Wilgus
4c34e150f7 [Fix Red] #2 7288d9e Move cfg_vals from settings_list
agc settings..

Change-Id: I695c9c8300fb5d4a544b12e3185dfec39cf7fbbc
2024-11-10 22:59:31 -05:00
William Wilgus
9baadd4a95 [Fix Red] 7288d9e Move cfg_vals from settings_list, expand settings_dumper
Change-Id: Ic1dc9eb46b5eed8adc1888e8b7e58d45f4f1c57a
2024-11-10 22:30:30 -05:00
William Wilgus
7288d9e5d2 Move cfg_vals from settings_list, expand settings_dumper
cfg_vals aren't needed for most settings

F_TABLE_SETTING, F_CHOICE_SETTING, F_BOOL_SETTING

can use cfg_vals but only a few custom settings use it otherwise
for these settings we define F_HAS_CFGVALS and use the setting union instead (as these all use UNUSED)

noticed that settings_dumper missed most cfg values so didn't show text setting values

saves ~300 bytes

Change-Id: Ie504c8cfe2a6cf471117c3afe5cf9a770a7f1784
2024-11-10 21:53:22 -05:00
Solomon Peachy
1516c48a37 storage: Support a default virtual sector size
Normally, we figure out the virual sector size from the filesystem info.
However, if there's no filesystem, we fall back to the hardware's
logical sector size.

Some device firmware (eg ipod5g/6g) need their partition tables set up
with larger-than-logical sector sizes; this way we can present the
"correct" sector size to maintain interoperability with the stock
firmware and make it so that the drive can still be properly partitioned
from within rockbox.

This patch adds support for DEFAULT_VIRT_SECTOR_SIZE.  Nothing uses it yet.

Change-Id: Iae746a50ffc37c51abb2c9b82d3c4596f1fa7559
2024-11-09 17:48:00 -05:00
Solomon Peachy
bc6c189dcb storage: rename MAX_LOG_SECTOR_SIZE to MAX_VIRT_SECTOR_SIZE
Change-Id: I34f00748c1b0935d65af5f0fc6bdd13356ff31e1
2024-11-09 16:32:40 -05:00
Roman Artiukhin
e519356c47 plugin: don't start plugin when another non-tsr plugin is running
Change-Id: Ie5fc8220e5d586a5493992719c55e9d2f235b090
2024-11-09 04:26:15 -05:00
Christian Soffke
eb91595988 fileop: display progress bar for single file deletion
Change-Id: Id895eb270b8ce1ad483c508c98d6318ba6069cf0
2024-11-09 04:25:48 -05:00
Solomon Peachy
3664d382e0 ata: if drive doesn't advertise a nonstandard sector size, default to 512
...Instead of SECTOR_SIZE, which might be different.  This way
we can properly validate the value.

Change-Id: I8e6ae5882792f301ac580a144556af94772f4cfe
2024-11-07 18:15:26 -05:00
Christian Soffke
0386469794 Fix incorrect UI font id in some plugins
see commit f19f3ef

Change-Id: I417929eaa9303d439725fb4f0c20d104de54f8b0
2024-11-07 17:45:09 +01:00
Roman Artiukhin
ee365f21c4 show track info: skip Comment and codec string copies
Comment copy was added in c647e62c as workaround for FS#11033 and no longer needed (I tested really long lines and scroll no longer throw any errors on my Sansa e200v2)

Change-Id: I96a5b26096829034692dffc2abc730ff2bdd5d9c
2024-11-07 07:59:52 -05:00
Solomon Peachy
c3d06d21df mikmod: Properly render with fonts larger than 6x8 pixels.
Change-Id: Ib3f8c2cf84e7b6565bb8a00b74e8a662b9980824
2024-11-06 20:18:45 -05:00
Solomon Peachy
10abb34e54 mikmod: Use current theme fonts, not the cut-down SYSFONT
Change-Id: Ia5fff04b22fbad1081fcca6c66bbb7ea7f82fef8
2024-11-06 15:18:33 -05:00
William Wilgus
d60dee6188 tagtree cleanup first letter menu code
no functional difference just some code shared and trimming of
unnecessary format strings

Change-Id: Ia6165508556790ea825e630a79946fbd2dafd9c1
2024-11-03 13:59:29 -05:00
William Wilgus
06986d27f0 Generate A-Z menus in the tagtree
this adds a new command %byfirstletter

%byfirstletter "custom_track" "Track A to Z" "title"
^ command       ^menu name     ^menu title   ^subitem

need a better name for subitem btw..

this patch also allows us to tell when we are in the BFL menu
by checking customaction == ONPLAY_CUSTOMACTION_FIRSTLETTER
we then enable spelling of the letters in the menu
it spells Numeric too but that shouldn't matter with the upcoming voice patch

Change-Id: I59815f697a4ef84a8cb540783b620d15f6670e00
2024-11-02 17:27:22 -04:00
Solomon Peachy
1c28cb439b Translation updates:
- Chinese Simplified (王吉)
 - Turkish (Mustafa YILDIZ)

Change-Id: I4499ecdbc2a96078870a74f8a56bd25fa4181a2f
2024-11-01 11:59:26 -04:00
Solomon Peachy
0a11b06d93 ata: Correct parsing of the logical sector size in the IDENTIFY DEVICE
....It's specified in 16-bit words, not bytes.  So multiply it by 2.

(This hasn't been a problem in practice as everything uses 512B logical
 sectors so far..)

Change-Id: I0b1abd0f6184330f0b7f5c000c5ad547038f7c95
2024-10-31 21:51:42 -04:00
Solomon Peachy
bf2a929f4e main: Include the version string in "no partitions found" error
Change-Id: I63ddecebb9d0e27eff27eedf5ec4b6e30508152f
2024-10-31 19:57:31 -04:00
Solomon Peachy
b30f05badc Revert "plugin load / tagtree retrieval: eliminate storage_disk_is_active check"
ata_disk_is_active() behavior with SSDs has reverted, so we want to keep this.

This reverts commit ef19fa4408.

Change-Id: I29f08617285747c17a52352bd7bba4069e71cde6
2024-10-31 12:52:00 -04:00
Solomon Peachy
e829ea9a5e ata: Rework how flushing, sleeping, and power off interacts
* FLUSH_EXT is used if featureflag is set and we are using LBA48
   (unconditionally used for CE-ATA on ipod6g)
 * FLUSH is used if featureflag is set (ATA6+) or if device claims to be ATA5+

 * Rename ata_disk_can_power_off() to ata_disk_can_sleep() as that is
   what it actually tests for.  Only use it to gate issuing the
   STANDBY IMMEDIATE command.
 * Restore behavior of ata_disk_is_active() to return 1 if drive is
   "spinning" or powered up.
 * Allow poweroff if drive claims PM support OR we are able to issue
   FLUSH/FLUSH_EXT commands.

 * Added ata_flush() to explicitly trigger a flush operation, and hook it
   up to storage_flush() in the device shutdown path. (Flushes were
   only previously used in the storage device power management path)

 * After issuing all settings, re-issue IDENTIFY_DEVICE to make sure
   it reflects everything we've enabled.

 * Update manual section on Flash/SSD mods.

Change-Id: I6770a54ef3a87f4c47120bcb96c944a6652f1bf4
2024-10-31 12:51:54 -04:00
Solomon Peachy
65241f5a32 Minor mechanical corrections to the Turkish translation
(The rest need to be made by someone who knows the language)

Change-Id: I3393291ccb3d18fd79012a6cc83556ed79e42437
2024-10-31 08:23:48 -04:00
Solomon Peachy
85330eb5fe Update multiple translations:
- English-US (Solomon Peachy)
 - German (Wilfried Winkler)
 - Italian (Alessio Lenzi)
 - Korean (Hoseok Seo)
 - Polish (Adam Rak)
 - Turkish (Mustafa YILDIZ)

Change-Id: I8ca5d6acb46bb86004e2d393cfce058dc85dc426
2024-10-31 08:08:22 -04:00
Roman Artiukhin
914a56f34c imageviewer: fix segfault when album art fails to load
Attempt to change file fails due to access to uninitialized memory with negative index

Fixup for 55a5bfe7

Change-Id: I9c42f66c856c1d4b7261da5e4996efbe9597bcd4
2024-10-29 09:44:06 +02:00
Solomon Peachy
bd02af3413 SD: Fix typo in debug menu
Change-Id: I55530ca7b3e735fef0ac6d4151e66ca11e571aa0
2024-10-28 13:53:30 -04:00
Roman Artiukhin
55a5bfe740 View Album Art from WPS context menu
Add ability to imageviewer to view current track embedded/folder album art
Add "View Album Art" WPS context menu item

Change-Id: I49caebd38e5e3e2910d418bbeaa5e51da0e6bd93
2024-10-28 12:46:51 -04:00
Solomon Peachy
c1bcebd998 FS#9059: Add WenQangYi Unibt font (William Poetra Yoga Hadisoeseno)
Change-Id: I8411349fdfdddf67f0d4a692d35176925498a7f6
2024-10-27 22:04:54 -04:00
Franklin Wei
5f4e0b6578 quake: Bail out of out-of-bounds draws
With this Quake should hopefully be able to run at native resolution
on smaller screens.

Change-Id: Ic30c8356eb2fd030a4cf84c54b63c9b688a9c14a
2024-10-27 10:49:23 -04:00
Franklin Wei
655d201cf3 quake: add a bunch more yield calls
Probably a bit too many, but good for making sound not skip.

Change-Id: I6657dcb4e8e7bb32c6550e2c5e3cee74d79b9ebe
2024-10-27 10:23:57 -04:00
Franklin Wei
54b3b6f797 quake: migrate to SDL_mixer and add background music
Kind of skippy and only supports WAV. MP3 would be nice, especially if
using Rockbox's codec.

Change-Id: I0bba195603da32da1e4d1dcf2ee821fa5696824a
2024-10-27 10:23:57 -04:00
Jean-Louis Biasini
fb93c99ce8 Fuze+: add pdbox plugin
1) Set the compiler to include pdbox
2) Set the keymaps

Change-Id: I75cf9b57ac977f7c727a28a3ed6883f65c5bbb20
2024-10-27 09:24:57 -04:00
Solomon Peachy
3951fbf9d2 ATA: Restrict to UDMA2 if we don't detect an "80-pin" cable
Change-Id: I55861065741f3365491445f1f3f5b0041f33e1c6
2024-10-26 15:09:10 -04:00
Solomon Peachy
aea4974b88 FS#13052: Update Italian translation (Alessio Lenzi)
Change-Id: Ica28186177e82b92f4d0f8f395161a16da9c7411
2024-10-26 13:00:43 -04:00
Christian Soffke
04a796fd15 playlist: create_control_unlocked: back up current playlist
When creating a new control file for the current playlist,
the existing file will now be renamed to serve as a backup,
until the next time the control file is replaced again,
allowing you to restore the previous state of the playlist,
in case you accidentally cleared it.

This also means that an entirely new file is created each
time, instead of truncating the existing one.

Change-Id: I2fd96eb8c3940b85df807fd7646dc0359a036351
2024-10-26 11:28:22 -04:00
Christian Soffke
7592d2ca5e playlist: deprecate PLAYLIST_COMMAND_CLEAR
In the following scenario, a garbage file name would
be written to the control file for the playing track
(resulting in a failure to resume correctly):

- "Keep Current Track When Replacing Playlist" option is set
- A track is playing that was not inserted but instead comes
  from a playlist file on disk
- User performs "Playing Next..." -> "Play" on some tracks, so
  that the current playlist is replaced (but leaving the playing
  track queued)
- User saves the playlist while queued track is still playing
  (the offer to remove queued tracks is declined)

The failure occurs because the pl_save_update_control function
assumes that the seek offset for queued files always points into
the control file. Meanwhile, the remove_all_tracks_unlocked
function adds the PLAYLIST_QUEUED flag indiscriminately, even if
a track comes from a playlist file instead of having been inserted.

Theoretically, this could be addressed by adding the playing
track's file name as a parameter to PLAYLIST_COMMAND_CLEAR,
which the track is then updated to point to, unless it
was already inserted (alternatively, we could seek within
the playlist file for such tracks).

Unless I'm missing something, it may be preferable, though, to
get rid of PLAYLIST_COMMAND_CLEAR completely, and instead have the
remove_all_tracks_unlocked function start over with a fresh
control file, into which we insert a single ('P' and) 'Q' command.

This seems to have several advantages:

- When resuming, we eliminate the need to parse and handle all of
  the outdated entries again that end up being cleared anyway
- It is ensured that the control file doesn't rely on the existence
  of a playlist file anymore after the playlist has been cleared
- We can reset the playlist's file name, which should make it less
  likely for the user to overwrite their previous (now unconnected)
  playlist that was still displayed in the Save dialog
- Unrelated bookmarks for the previous playlist aren't displayed
  anymore
- Improved consistency with existing behavior when the "Keep
  Current Track When Replacing Playlist" was disabled.

Change-Id: I41a89295bbac878807d65db9cf67b8a485daf0e5
2024-10-26 11:28:01 -04:00
Roman Artiukhin
cb1346b640 Ignore zero bytes between markers in built-in jpeg decoder
For consistency between built-in and imageviewer jpeg decoders.

Change-Id: I2aab5923ee096b99a7def49dcdc436b872823971
2024-10-23 21:17:35 -04:00
Roman Artiukhin
7912bf3bee Fix prev/next folder action leads to immediate ff/rewind
Removed check that was introduced in 54e6bafa. This check doesn't work in WPS as BUTTON_NONE actions come while you still have button pressed. I believe the proper fix for this is already commited in c354e0bd.

Fixes FS#13370

Change-Id: I86e92c296c0bfa42caaed9cb3540e311630daf9c
2024-10-22 16:28:22 +03:00
Roman Artiukhin
c354e0bd1f buttons: Don't set wait_for_release for release action
Fixes ignored button press in yes/no screen.
It depends on keymapping - this issue happens if action before wait_for_release is mapped on release action. Something like:
{ ACTION_STD_OK, BUTTON_SELECT|BUTTON_REL, BUTTON_SELECT }

Change-Id: Idc6a57ef7a7daf75c21c9887e07fbefc814b6ae3
2024-10-22 06:52:28 -04:00
Solomon Peachy
5a3d62dabb Translation updates
- chinese-simp: 王吉
 - deustch:      Wilfried Winkler
 - english-us:   Solomon Peachy
 - korean:       Hoseok Seo
 - polish:       Adam Rak

Change-Id: I116ec67161d59293824aa579eba8a6912c06d45a
2024-10-22 06:48:35 -04:00
Christian Soffke
8c1c8597ac plugins: playing time: OBOE
Change-Id: I1c6b73e06ac615db6e764aa54f042ec4e2dee3a2
2024-10-18 06:55:15 +02:00
Solomon Peachy
ac46684d7f janitorial: Use ATTRIBUTE_PRINTF(X,Y) instead of __attribute__((format(printf,X,Y)))
Change-Id: Ia66e7647bdd9e8e1c28b9d8636cae8db82825841
2024-10-17 21:39:41 -04:00