SDL_DestroyTray(3)
π SDL_DestroyTray(3) π
okay bestie, welcome to the SDL3 FUNCTIONS corner of the manual, where we are literally about to say goodbye to a tray icon π
β¨ NAME β¨
SDL_DestroyTray β destroys a tray object. that's it, that's the whole job, and she does it flawlessly π
πΈ SYNOPSIS πΈ
#include <SDL3/SDL_tray.h>
void SDL_DestroyTray(SDL_Tray *tray);
like, look at her. one header, one function, zero drama (well, okay, a little drama, it's a destructor) π¦
π«Ά DESCRIPTION π«Ά
so when you call this, the tray goes bye-bye π but here's the part that matters, no cap: this also destroys all associated menus and entries. all of them. every single one. the whole little family tree of menus and entries you built under that tray? gone. it's giving "we're clearing the whole group chat, not just muting it" π
so don't be out here thinking you can destroy the tray and then keep poking at those menus afterwards, because you cannot, and that's not a vibe you want π₯
π FUNCTION PARAMETERS π
trayβ the tray icon to be destroyed. yes queen, hand her over π
π§ THREAD SAFETY π§
this one is important so listen up fr fr: this function should be called on the thread that created the tray. like, the same thread. the one that made it. the origin story thread π
not me calling it from some random thread and then acting surprised when things go feral π don't do that. match the thread. periodt.
β AVAILABILITY β
this function is available since SDL 3.2.0. so if you're on anything older, bestie, she is simply not there π
π SEE ALSO π
SDL_CreateTray(3)β the one that started it all, the birth to this destruction, the yin to this yang π
and that's the page!! tysm for reading, you ate that π
cute little sign-off time: this came to you from Simple Directmedia Layer, version SDL 3.4.18, and yes the date is in there too, it's the same page, it's the same energy, we're just saying it with love instead of in a footer ππβ¨
π¦ 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