Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
tsl0922 authored Jan 9, 2024
1 parent 60edd00 commit eeea4c8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ If both `menu.dll` and `menu.lua` exists in scripts folder, one of it may be nam

- `max_title_length=80`: Limits the title length in dynamic submenu, set to 0 to disable.

## Updating menu from another plugin
## Updating menu from script

The menu data is stored in `user-data/menu/items` property with the following structure:

Expand All @@ -85,6 +85,8 @@ MPV_FORMAT_NODE_ARRAY

Updating this property will trigger an update of the menu UI.

To reduce update frequency, it's recommended to update this property in [mp.register_idle(fn)](https://mpv.io/manual/master/#lua-scripting-mp-register-idle(fn)).

## Credits

This project contains code copied from [mpv](https://github.com/mpv-player/mpv).
Expand Down

0 comments on commit eeea4c8

Please sign in to comment.