SDL_GetTrayMenu(3)
π SDL_GetTrayMenu π
okay bestie, this one's from the SDL3 functions crew β it's the little getter that hands you back a tray menu you already made. no cap, that's the whole vibe. π
β¨ NAME β¨
SDL_GetTrayMenu β gets a previously created tray menu. that's it, that's the job. π
πΈ SYNOPSIS πΈ
#include <SDL3/SDL_tray.h>
SDL_TrayMenu * SDL_GetTrayMenu(SDL_Tray *tray);
π¦ DESCRIPTION π¦
so here's the lore: you should have already called SDL_CreateTrayMenu() on the tray object. this function is literally just the "hey, can I see that again?" button β it lets you fetch it again later. lowkey it's a lil reunion. π«Ά
the way that this is the same thing as SDL_GetTraySubmenu(), except it takes a SDL_Tray instead of a SDL_TrayEntry? iconic. same energy, different input type, iykyk. β¨
and here's the part that's actually a relief: a menu does not need to be destroyed. it will be destroyed with the tray. so no manual cleanup arc for you, the tray handles it. periodt. π
π FUNCTION PARAMETERS π
trayβ the tray entry to bind the menu to.
β RETURN VALUE β
returns the newly created menu. that's your menu, bestie, go be a main character with it. π
π§΅ THREAD SAFETY π§΅
this function should be called on the thread that created the tray. like, same thread, same energy, no jumping around. π
π AVAILABILITY π
this function is available since SDL 3.2.0. β¨
π SEE ALSO π
okay so that's the whole page!! this lil cutie comes to you from the Simple Directmedia Layer squad, version SDL 3.4.18, and it's SDL_GetTrayMenu(3) forever and ever. go get your menu back, you absolute legend. π¦πβ¨
π¦ where this page comes from
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 43: SDL3-devel 3.4.18-1.fc43 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- fedora 44: SDL3-devel 3.4.18-1.fc44 Β· Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 OR MIT)
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms