#include "core/gooey_backend_internal.h"
#include "gooey_widgets_internal.h"
Go to the source code of this file.
◆ GooeyMenu_AddChild()
GooeyMenuChild * GooeyMenu_AddChild |
( |
GooeyWindow * |
win, |
|
|
char * |
title |
|
) |
| |
Adds a child menu item to the window's menu.
- Parameters
-
win | The window to add the menu item to. |
title | The title of the menu item. |
- Returns
- A new GooeyMenuChild object.
◆ GooeyMenu_Draw()
void GooeyMenu_Draw |
( |
GooeyWindow * |
win | ) |
|
◆ GooeyMenu_HandleClick()
void GooeyMenu_HandleClick |
( |
GooeyWindow * |
win, |
|
|
int |
x, |
|
|
int |
y |
|
) |
| |
Handles menu item click events.
- Parameters
-
win | The window containing the menu. |
x | The x-coordinate of the click event. |
y | The y-coordinate of the click event. |
◆ GooeyMenu_Set()
GooeyMenu * GooeyMenu_Set |
( |
GooeyWindow * |
win | ) |
|
Sets the menu for the Gooey window.
Initializes and sets the menu for the given window.
- Parameters
-
win | The window to set the menu for. |
- Returns
- A new GooeyMenu object.
◆ GooeyMenuChild_AddElement()
void GooeyMenuChild_AddElement |
( |
GooeyMenuChild * |
child, |
|
|
char * |
title, |
|
|
void(*)() |
callback |
|
) |
| |
Adds a menu item to a menu child.
- Parameters
-
child | The menu child to add the item to. |
title | The title of the menu item. |
callback | The callback function to call when the item is selected. |