Commit graph

98 commits

Author SHA1 Message Date
Aidan MacDonald
5b27e2255a Add perceptual volume adjustment
The perceived loudness change of a change in volume depends
on the listening volume: at high volumes a 1 dB increment is
noticeable, but at low volumes a larger increment is needed
to get a comparable change in loudness.

Perceptual volume adjustment accounts for this fact, and
divides the hardware volume range into a number of steps.
Each step changes the dB volume by a variable amount, with
most of the steps concentrated at higher volumes. This
makes it possible to sweep over the entire hardware volume
range quickly, without losing the ability to finely adjust
the volume at normal listening levels.

Use "Volume Adjustment Mode" in the system settings menu
to select perceptual volume mode. The number of steps used
is controlled by "Number of Volume Steps". (Number of steps
has no effect in direct adjustment mode.)

It's still possible to set a specific dB volume level from
the sound settings menu when perceptual volume is enabled,
and perceptual volume does not affect the volume displayed
by themes.

Change-Id: I6f91fd3f7c5e2d323a914e47b5653033e92b4b3b
2023-01-22 21:19:57 +00:00
Aidan MacDonald
767ddef550 quickscreen: Settings ID to pointer conversion
Saves a good deal of code...

Change-Id: Ibaf4138ddffd5d8f7cca560cc52645dbce44149c
2022-12-17 13:36:38 +00:00
William Wilgus
6b87bfadff wps.c cleanup gui_show_wps
remove some old cruft move a few things around clean-up flow

Change-Id: I138c6cd9e2d58ef526eb686333da413819df725d
2022-12-14 22:35:33 -05:00
Christian Soffke
dfd9c10589 Eliminate skin updates in between activities
1) Adds way to pop activity without refreshing the skin at
the same time.

Activities are sometimes popped in immediate succession,
or one activity is popped before another one is pushed right
away. This can lead to the UI appearing glitchy, due to an
activity only appearing for a split-second, which is especially
noticeable with complex skins that change the dimensions
of the UI viewport depending on the current activity

To fix this, prevent superfluous skin updates

* when switching between:
- WPS and browser
- WPS and Playlist Catalogue
- WPS and playlist
- WPS and Settings/System/Plugins

* when accessing Track Info or when displaying
bookmarks using the context menu on the WPS

* when switching from QuickScreen to Shortcuts Menu

2) The playlist viewer activity was pushed & popped
redundantly by playlist_view.

----
NB:
Behavior has remained unchanged in all instances of the
code where pop_current_activity() has been replaced by
pop_current_activity(ACTIVITY_REFRESH_NOW).

Change-Id: I56b517b8c9dba823a9fed3a3f558d7469dcea9fd
2022-12-11 11:50:33 +01:00
Christian Soffke
193ebb5a36 Enable access to Shortcuts Menu from QuickScreen
Offers a quick way of switching to the Shortcuts Menu
by pressing the 'context menu' button while QuickScreen
is active (e.g. long press Select on iPods and some other
players)

Change-Id: I38292c7070cf093a81e1db688809b1f0d6a8764a
2022-10-25 03:26:51 +02: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
Christian Soffke
bc5a638594 Option to switch off album art or to prefer file over embedded
Large embedded album art can cause pauses during
playback or when skipping between tracks, especially
on older devices, but embedded art is currently loaded
even when separately stored smaller image files would be
available.

A workaround is to remove large album art from the
metadata of files.

This now adds a setting to either turn off loading of
album art completely, or to prefer loading the album art
from a separate image file and thus ignore the embedded
versions.

Change-Id: I22fb581abf56072e35e6c29d72e553747ec1a96a
2022-01-22 08:29:40 -05:00
Aidan MacDonald
3f966b2aa4 touchscreen: make quickscreen easier to use
In absolute pointing mode, the quickscreen now accepts
a touch anywhere in the middle third of the screen edge
to trigger an item, and pressing anywhere else on the
'grid' will exit -- the same as how 3x3 mode works.

Previously it required a touch inside the text viewport
to trigger an item, and exited after any touch outside
the viewports. This made it very difficult to use since
the text viewports are too small to reliably touch.

Change-Id: I971eaeb4a2c67bebef3d7b070a29b897df07b8e7
2021-11-21 20:26:21 +00:00
Aidan MacDonald
a14347a6b3 quickscreen: fix non-intuitive behavior of top/bottom items
The behavior of the top/bottom items is not intuitive when used
with settings like volume or brightness -- pressing up will
actually *decrease* the setting, and down will increase it.
This patch inverts the direction, so the top item will increase
the setting.

The reason for this is that historically, the quickscreen seems
to have had only 3 directions -- left, right, and bottom. Bottom
therefore selected the next value, and when top was introduced
it selected the previous value.

The counter-intuitive nature of this was later reported as a bug
on the Fuze V2 and got an incorrect fix (commit 2271995517) under
the assumption that ASCENDING_INT_SETTINGS was the issue.

Change-Id: I3be92534469cea4f5efd81ab024288c052367411
2021-11-20 22:07:29 -05:00
Christian Soffke
4f374b3862 QuickScreen: Update status bar after changing volume
So that (e.g.) a skin's custom volume bar doesn't appear choppy during
volume adjustments

Change-Id: I65b9c46ccbdea3f2cb84c418d5d2e33e0121acc9
2021-04-04 00:14:37 +02:00
William Wilgus
9712d375ce Shortcuts.c -- Update
Fix returns from shortcuts -- should now run plugins
Fix formatting of file names to remove path from browser shortcuts

Change-Id: I46e337110d04b84bedcb0c2945d5dd29a1860847
2021-03-07 10:07:49 -05:00
Christian Soffke
cde5ae755f iPods: Allow using scroll wheel to change volume on QuickScreen
As suggested by forum user yuuiko

Change-Id: Ifb989f9513a9e3c59e4ab0f38c0a8e2675c68dd8
2021-03-03 22:37:14 +00:00
Moshe Piekarski
362f7a3220 Quickscreen: don't apply glabal settings
Change-Id: I4de0e35b4c3227513f9c384bc0e01bc468999317
2020-11-12 21:23:57 +00:00
William Wilgus
3237ae4a4f LCD core move buf ptr and address look up function viewport struct
I'm currently running up against the limitations of the lcd_draw functions
I want these functions to be able to be used on any size buffer not
just buffers with a stride matching the underlying device

[DONE] allow the framebuffer to be decoupled from the device framebuffer
[DONE need examples] allow for some simple blit like transformations
[DONE] remove the device framebuffer from the plugin api
[DONE}ditto remote framebuffer
[DONE] remove _viewport_get_framebuffer you can call struct *vp = lcd_set_viewport(NULL) and vp->buffer->fb_ptr

while remote lcds may compile (and work in the sim) its not been tested on targets

[FIXED] backdrops need work to be screen agnostic

[FIXED] screen statusbar is not being combined into the main viewport correctly yet

[FIXED] screen elements are displayed incorrectly  after switch to void*

[FIXED] core didn't restore proper viewport on splash etc.

[NEEDS TESTING] remote lcd garbled data

[FIXED] osd lib garbled screen on bmp_part

[FIXED] grey_set_vp needs to return old viewport like lcd_set_viewport

[FIXED] Viewport update now handles viewports with differing buffers/strides by copying to the main buffer

[FIXED] splash on top of WPS leaves old framebuffer data (doesn't redraw)
[UPDATE] refined this a bit more to have clear_viewport set the clean bit and have skin_render do its own screen clear
scrolling viewports no longer trigger wps refresh
also fixed a bug where guisyncyesno was displaying and then disappearing

[ADDED!] New LCD macros that allow you to create properly size frame buffers in you desired size without wasting bytes
(LCD_ and LCD_REMOTE_)
LCD_STRIDE(w, h) same as STRIDE_MAIN
LCD_FBSTRIDE(w, h) returns target specific stride for a buffer W x H
LCD_NBELEMS(w, h) returns the number of fb_data sized elemenst needed for a buffer W x H
LCD_NATIVE_STRIDE(s) conversion between rockbox native vertical and lcd native stride (2bitH)
test_viewports.c has an example of usage

[FIXED!!] 2bit targets don't respect non-native strides
[FIXED] Few define snags

Change-Id: I0d04c3834e464eca84a5a715743a297a0cefd0af
2020-10-26 12:28:48 -04:00
Solomon Peachy
f68463c53e quickscreen: Get rid of a vestigal remnant of the Archos code.
Change-Id: I1dd7e82edfdbcc3a79aa5deaa604ac1623aa16d4
2020-10-12 19:26:26 -04:00
Solomon Peachy
8143e4437b Speech Feedback improvements on the Quickscreen
Patch by Igor Poretsky

Change-Id: I1bb94965cb18efaa0787d7780f6cf22814231144
2019-08-05 05:01:29 +02:00
Thomas Martitz
ea9621c018 Fix build reds caused by typos.
Change-Id: I71cdca3b6e73e29d487e0c6d02a69a31dcf3e6bf
2014-03-18 12:31:09 +01:00
Thomas Martitz
395cdc5945 quickscreen: return true on USB connection.
This is consistent with other screens (pitch, id3) on the WPS and in other
places.

Change-Id: Iafae52507867ff9815a60cf44faaf09a29c55091
2014-03-18 12:24:16 +01:00
Thomas Martitz
1c5d0b41ee scroll_engine: Rename scroll_stop* functions to be more consistent with the lcd api.
Change-Id: I8ada10b96bfb628cca0331689e8b936ae47c7e1c
2013-12-14 23:11:30 +01:00
Frank Gevaerts
e6fd7d2d1f Make the recorder build with HAVE_LCD_FLIP disabled.
Change-Id: I5875dc5c59606867299cc0e30d869b817e879ade
2012-08-28 21:36:23 +02:00
Michael Sevakis
57a20d2d63 Make DSP's replaygain independent of global_settings.
Moves replaygain definitions to lib/rbcodec/dsp/dsp_misc.h.
Intermediate functions in misc.c handle any adjustment and calling
the rbcodec APIs.

Change-Id: I9f03561bca9aedd13760cf19c4e19aa3c68e7024
Reviewed-on: http://gerrit.rockbox.org/140
Reviewed-by: Michael Sevakis <jethead71@rockbox.org>
2012-04-30 22:47:37 +02:00
Michael Sevakis
56f17c4164 Make rbcodec/dsp includes more specific.
Change-Id: Idb6af40df26f5b8499a40e8b98602261ef227044
2012-04-29 17:31:30 -04:00
Jonathan Gordon
6f62226294 quickscreen: optionally display the shortcuts menu instead of the QS
Adds an option under settings > general settings > system to allow
the user to have the shortcuts menu displayed instead of the
quick screen. (option is "shortcuts instead of quickscreen" in the .cfg)

Change-Id: Id679b461c40ac617629422736d1509384364084d
Reviewed-on: http://gerrit.rockbox.org/199
Reviewed-by: Marek Salaba <marek.salaba@gmail.com>
Reviewed-by: Jonathan Gordon <rockbox@jdgordon.info>
2012-03-28 10:56:12 +02:00
Björn Stenberg
0942e2a0f7 Changed the FOR_NB_SCREENS macro to always be a for loop that declares its own loop variable. This removes the need to declare this variable in the outer scope.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30756 a1c6a512-1295-4272-9138-f99709370657
2011-10-15 19:35:02 +00:00
Jonathan Gordon
4983d052a0 Remove to top/bottom quickscreen defaults.
As constantly discussed in IRC, it is insane that dirfilter and party mode are defaults on the quickscreen, both have caused countless problems for users accidentaly enabling them.
This wont change anything for users who have changed their setting, only for people who left it default

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30176 a1c6a512-1295-4272-9138-f99709370657
2011-07-20 01:30:29 +00:00
Jonathan Gordon
b58d3656d7 FS#11925 - Add a proper system to keep track of the current screen/activity to make %cs far more useful
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29944 a1c6a512-1295-4272-9138-f99709370657
2011-06-01 14:41:49 +00:00
Andree Buschmann
e75018ad66 Fix several 'variable set but not used' warnings reported from GCC 4.6.0.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29805 a1c6a512-1295-4272-9138-f99709370657
2011-05-01 11:42:41 +00:00
Jonathan Gordon
2271995517 invert the quickscreen setting direction on wheel targets for settings which are number lists so pressing up makes it bigger (i.e contrast). fixes http://forums.rockbox.org/index.php/topic,27778.0.html
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29772 a1c6a512-1295-4272-9138-f99709370657
2011-04-24 07:04:52 +00:00
Magnus Holmgren
a14f4acb0c Restore the 'read_disk' flag for settings_apply that was removed in r24922. It is still needed to prevent uncessary disk I/O for fonts etc. Should fix FS#11071 (I haven't tested it on a HD-based player).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25042 a1c6a512-1295-4272-9138-f99709370657
2010-03-06 12:14:12 +00:00
Jonathan Gordon
4c6b3551b5 split the theme settings apply() sutff out of settings_apply(). this should fix splashes not being loc'ed, statusbar over the splash (fixed in sim, not on my mini2g though), and the supposed boot time slowdown.
What this also does is remove a bunch of unnecessary settings_Apply()'s from the ipod accessory code, and causes all non-skin settings to get applied each time (this includes font and langs which we wernt doing to stop disk access)


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24922 a1c6a512-1295-4272-9138-f99709370657
2010-02-26 08:01:41 +00:00
Jonathan Gordon
cf6be66db6 small change to how the quickscreen fixes its viewports
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24918 a1c6a512-1295-4272-9138-f99709370657
2010-02-26 06:17:04 +00:00
Teruaki Kawashima
51bc09e88e Quickscreen: add more check for case that qs item is not set.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24901 a1c6a512-1295-4272-9138-f99709370657
2010-02-25 06:01:53 +00:00
Tomer Shalev
9d268d796c Quickscreen: Hande case where not all quick settings are defines
This happens in Archos Recorder, see quick_screen_f3(), which caused crash
(FS#11037), due to top item not defined.
The commit explicitly sets items[QUICKSCREEN_TOP] to NULL, and also draws an
arrow only if the item is defined.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24871 a1c6a512-1295-4272-9138-f99709370657
2010-02-23 21:30:16 +00:00
Nils Wallménius
67f616478a Const correctness
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23402 a1c6a512-1295-4272-9138-f99709370657
2009-10-29 15:09:09 +00:00
Nils Wallménius
ff197a4706 Use array for quickscreen item settings to simplify some logic
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23380 a1c6a512-1295-4272-9138-f99709370657
2009-10-28 20:41:34 +00:00
Thomas Martitz
72f93e5f10 Cleanup quickscreen text drawing by using text alignment flags for viewports.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23283 a1c6a512-1295-4272-9138-f99709370657
2009-10-19 22:49:47 +00:00
Nils Wallménius
15514b0dc6 Deinline fuction and some whitespace tweaks
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23062 a1c6a512-1295-4272-9138-f99709370657
2009-10-10 07:46:54 +00:00
Thomas Martitz
c17037a802 Factor out/generalise the function that checks whether a point is within a viewport to, and use it in the wps' touchregion code. This corrects the check that was done there.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22638 a1c6a512-1295-4272-9138-f99709370657
2009-09-05 23:57:09 +00:00
Thomas Martitz
a17d06ccc3 Improve and simplify touchscreen handling of the quickscreen in absolut mode - and implement handling for the top item.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22637 a1c6a512-1295-4272-9138-f99709370657
2009-09-05 23:32:16 +00:00
Thomas Martitz
9c938a23b9 Don't forget the touchscreen targets!
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22636 a1c6a512-1295-4272-9138-f99709370657
2009-09-05 19:04:23 +00:00
Thomas Martitz
4034e0b47f Put the quickscreen viewports onto the stack (saving a tiny bit of ram), and simplify the preparing and drawing functions a bit.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22634 a1c6a512-1295-4272-9138-f99709370657
2009-09-05 18:52:44 +00:00
Thomas Martitz
42e6638420 Fix bug in viewports preparation (screen.lcdwidth() isn't really proper for this in times of custom ui vp), and stop all scrolling before exiting (fixes FS#10584).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22631 a1c6a512-1295-4272-9138-f99709370657
2009-09-05 14:38:29 +00:00
Alessio Lenzi
9b700b2861 Added a missing line for spoken QUICKSCREEN_TOP item in Quick Screen.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22591 a1c6a512-1295-4272-9138-f99709370657
2009-09-01 09:40:32 +00:00
Thomas Martitz
e454a39852 Quickscreen: 4th item
This adds a 4th top item to the quickscreen. It's as configurable as the existing three items.
This patch goes along with optimisations for small screens for better displaying of all four items. 14px font is very usable on a 64px height display for example.
Left and Top items go through the items in the opposite direction, so that you can mirror a setting and toggle through it in both directions.
Default item is party mode, as it's target independant.

Flyspray: FS#9706

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22532 a1c6a512-1295-4272-9138-f99709370657
2009-08-29 14:42:03 +00:00
Nils Wallménius
3200d04d75 Make the formatter functions used by the settings return a pointer to avoid usless copying of lang strings, this brought with it a long chain of const correctness and a few random cleanups
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22440 a1c6a512-1295-4272-9138-f99709370657
2009-08-20 16:47:44 +00:00
Thomas Martitz
279ef752cb Make quickscreen items enum name lower-case, as per docs/CONTRIBUTING.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22291 a1c6a512-1295-4272-9138-f99709370657
2009-08-13 14:39:31 +00:00
Thomas Martitz
20b9bc5c0a Make gui_syncquickscreen_run() static as it's not used anywhere.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22290 a1c6a512-1295-4272-9138-f99709370657
2009-08-13 14:27:06 +00:00
Jonathan Gordon
d48f1a0a45 get the quickscreen working on the mr500. hold "mode" on the remote to get to it, then you can use the 4 directions on the remote, or the touchscreen to change the values. "mode" will exit, as will pressing in the top or middle of the main screen
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20935 a1c6a512-1295-4272-9138-f99709370657
2009-05-15 05:08:28 +00:00
Bertrik Sikken
09085a30f6 Remove unneeded #include "backdrop.h"
Remove unneeded #include "statusbar.h"


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20891 a1c6a512-1295-4272-9138-f99709370657
2009-05-09 18:09:14 +00:00
Karl Kurbjun
2677886bc3 Keep the quickscreen from crashing the player with a divide by 0
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20854 a1c6a512-1295-4272-9138-f99709370657
2009-05-06 02:17:04 +00:00