sdlCreateTrayMenu function
Create a menu for a system tray.
This should be called at most once per tray icon.
This function does the same thing as SDL_CreateTraySubmenu(), except that it takes a SDL_Tray instead of a SDL_TrayEntry.
A menu does not need to be destroyed; it will be destroyed with the tray.
\param tray the tray to bind the menu to. \returns the newly created menu.
\since This function is available since SDL 3.2.0.
\sa SDL_CreateTray \sa SDL_GetTrayMenu \sa SDL_GetTrayMenuParentTray
extern SDL_DECLSPEC SDL_TrayMenu *SDLCALL SDL_CreateTrayMenu(SDL_Tray *tray)
Implementation
Pointer<SdlTrayMenu> sdlCreateTrayMenu(Pointer<SdlTray> tray) {
final sdlCreateTrayMenuLookupFunction = libSdl3.lookupFunction<
Pointer<SdlTrayMenu> Function(Pointer<SdlTray> tray),
Pointer<SdlTrayMenu> Function(
Pointer<SdlTray> tray)>('SDL_CreateTrayMenu');
return sdlCreateTrayMenuLookupFunction(tray);
}