These options have been removed:
```
timeline_opacity
timeline_chapters_opacity
volume_opacity
speed_opacity
menu_opacity
menu_parent_opacity
top_bar_title_opacity
window_border_opacity
curtain_opacity
```
and replaced with one comma delimited `opacity` list to override all of the above and some new default opacity values.
Example:
```
opacity=timeline=0.5,title=0.5
```
List of opacity values available for override and their current defaults:
```
timeline=.9
position=1 # timeline progress or line
chapters=0.8
slider=0.9 # background of all sliders, such as volume
slider_gauge=1 # value bar of all sliders
speed=0.6
menu=1
submenu=0.4
border=1 # window border
title=1 # window title
tooltip=1 # tooltip background
thumbnail=1 # thumbnail border
curtain=0.5
```
closes#584, closes#636, closes#675
* feat!: reworked config options for fullscreen scale adjustments
Removed options:
```
timeline_size_fullscreen
controls_size_fullscreen
volume_size_fullscreen
menu_item_height_fullscreen
menu_min_width_fullscreen
top_bar_size_fullscreen
```
Additionally, `ui_scale` has been renamed to `scale`.
The scaling can now be controlled by these two new options:
```
scale=1
scale_fullscreen=1.3
```
closes#543
* feat: reworked timeline progress mode
Config options:
```
timeline_line_width_fullscreen=3
timeline_line_width_minimized_scale=10
timeline_size_min=2
timeline_size_max=40
timeline_size_min_fullscreen=0
timeline_size_max_fullscreen=60
timeline_start_hidden=no
```
have been replaced with:
```
timeline_size=40
timeline_size_fullscreen=60
progress=windowed
progress_size=2
progress_line_width=20
```
This simplifies stuff a bunch, and enables timeline's progress mode to be togglable at all times. Previously you could only toggle when it was configured to be visible in current context.
closes#630
- `open-menu` now only opens the menu, while closing any existing one first, even if it has the same `type`.
- `update-menu` will only update a currently opened menu of the same type. If no menu is open, or current menu's type is different, it doesn't do anything.
- `close-menu [type]` can be used to close any currently opened menu when called without a `[type]` argument, or only a menu of `[type]` type.
- uosc now keeps track of a currently opened menu type on the `user-data/uosc/menu/type` property, accessible via `mp.get_property_native('user-data/uosc/menu/type')`. This property is `nil` if no uosc menu is opened.
This is to achieve a predictable and granular control of menus with no implicit magic going on in the background.
The main difference is that `open-menu` can no longer be used to toggle the menu. You have to implement toggling manually by calling `open-menu` or `close-menu [type]` when appropriate. You can check if your menu is still opened either by getting or observing the `user-data/uosc/menu/type` property, or using the `on_close` menu callback.
This is currently limited to Mac & Linux only, since on Windows we have no way of telling a file is hidden (`file_info()` doesn't expose this information).
closes#647
Due to a recent change in mpv writing to playlist-pos doesn't restart
playback anymore, which was necessary for the format change to work for
the current file.
4b2276b730
mpv is about to remove `shared-script-properties`, which will cause
`utils.shared_script_property_set` to be nil.
Check for it's existence before calling it.
* feat: make the menu searchable
Each menu/submenu can have a `on_search` and `search_debounce`.
`search_debounce` supports the special value 'submit' with which
searches only get executed upon pressing ctrl+enter.
Without a `on_search` an internal search implementation gets used.
The internal search has it's own menu update function that is needed to
keep the same menu item objects around because otherwise updates to
children get discarded when the parent search gets updated.
* feat: add `menu_type_to_search` option
Always listening to text breaks toggling the menu via a single keybind.
Add an option so users can choose to manually activate the search.
Options can be changed during runtime by changing `script-opts`.
So far such option changes were simply ignored.
Now most options work, and the rest can be implemented when the needed.
Circular buffers are more efficient then moving the entries around.
Cursor velocity is now calculated on the fly, with from the current
cursor position and time as well a cursor position that is either
the youngest sample >100ms old, or the oldest sample in the buffer,
which is 10 elements in size. Restricting the sample selection based on
time prevents the filter window from becomming too long in case of
setups with low cursor update frequency, while still bring more
responsive velocity measurements to systems with higher cursor update
frequencies.
Removed the timer for exact seeking after fast seeks, as fast/exact
seeks can now be controlled with cursor speed and thus there is no need
for this anymore.
Splits the monolith file into individual modules with as little code refactoring as possible.
Not too happy with it, mainly because of the weird language server behavior where it doesn't recognize types or variables unless the files defining them are open...
It'd also be better to refactor everything from the ground up to not depend on global variables but if I had that much time to invest I'd straight up just rewrite everything in typescript and use TS→Lua transpiler.