tomasklaen / uosc

Feature-rich minimalist proximity-based UI for MPV player.
GNU Lesser General Public License v2.1
1.85k stars 69 forks source link

Allow icons and actions for (item) submenus #1011

Closed itsmeipg closed 3 weeks ago

itsmeipg commented 3 weeks ago

I can't change the icon/add actions for items containing items, even though I can make them active.

tomasklaen commented 3 weeks ago

Actions don't show up for submenu buttons. They don't have values so the API wouldn't work, and action buttons would clash with submenu preview.

We could add values to submenus to support this, but I don't know what to do with the preview then, and overall I feel like this shouldn't be a thing.

itsmeipg commented 3 weeks ago

Oh okay that makes sense. Btw another small issue I have is action buttons not showing if selectable is false. Idk if I should open another issue (I made so many).

tomasklaen commented 3 weeks ago

Should they show up when selectable is false? Setting it to false implies the item is inactive, shouldn't be interacted with. It's used to make titles/separators. I wouldn't expect actions to show on those.

itsmeipg commented 3 weeks ago

image I have a color menu that displays color properties with actions on the side to increase/decrease the values. Clicking the item does nothing so I think it should be unselectable. I think if an item is set to be unselectable, then it should be up to the menu creator to remove any existing actions (if they want).

Edit: Actually if I imagine it, it would look kinda weird tbh.