mirror of
https://github.com/labwc/labwc.git
synced 2025-11-01 22:58:47 -04:00
menu: support pipe menus
See labwc-menu(5) for usage. Co-authored-by: @Consolatis
This commit is contained in:
parent
e5488fefcb
commit
f3b68b8fb5
3 changed files with 506 additions and 65 deletions
|
|
@ -29,6 +29,8 @@ struct menu_scene {
|
|||
|
||||
struct menuitem {
|
||||
struct wl_list actions;
|
||||
char *execute;
|
||||
char *id; /* needed for pipemenus */
|
||||
struct menu *parent;
|
||||
struct menu *submenu;
|
||||
bool selectable;
|
||||
|
|
@ -46,6 +48,7 @@ struct menu {
|
|||
char *label;
|
||||
int item_height;
|
||||
struct menu *parent;
|
||||
|
||||
struct {
|
||||
int width;
|
||||
int height;
|
||||
|
|
@ -57,6 +60,8 @@ struct menu {
|
|||
struct menuitem *item;
|
||||
} selection;
|
||||
struct wlr_scene_tree *scene_tree;
|
||||
bool is_pipemenu;
|
||||
enum menu_align align;
|
||||
|
||||
/* Used to match a window-menu to the view that triggered it. */
|
||||
struct view *triggered_by_view; /* may be NULL */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue