wxWindowDestroyEvent(3)
π NAME π
wxWindowDestroyEvent β this event gets sent as early as possible during the window destruction process. that's it, that's the vibe β¨
πΈ DESCRIPTION πΈ
okay bestie, listen up, because the timing here is the whole entire plot.
For the top level windows, "as early as possible" means it's done by the wxFrame or wxDialog destructor, i.e. after the destructor of the derived class was executed β so any methods specific to the derived class can't be called any more from this event handler. π if you need to do that, you must call wxWindow::SendDestroyEvent() (not implemented in wx) from your derived class destructor. yeah. that's the rule.
For the child windows, this event is generated just before deleting the window from wxWindow:'Destroy'/1 (which is also called when the parent window is deleted) or from the window destructor if operator delete was used directly (which is not recommended for this very reason π).
It is usually pointless to handle this event in the window itself, but it can be very useful to receive notifications about the window destruction in the parent window or in any other object interested in this window. like, main character energy belongs to the observer, not the window π
See:
- Overview events
wxWindowCreateEvent
This class is derived, and can use functions, from:
wxCommandEventwxEvent
wxWidgets docs: wxWindowDestroyEvent
π DATA TYPES π
wxWindowDestroy() :: #wxWindowDestroy{}.wxWindowDestroyEvent() :: wx:wx_object().wxWindowDestroyEventType() :: destroy.
β FUNCTIONS β
(no functions listed here, bestie β this one's just the event definition, slay π«Ά)
and that's the whole page! brought to you by Ericsson AB π, version wx 2.6, and the one and only wxWindowDestroyEvent(3). no cap, go forth and destroy your windows responsibly ππ¦
π¦ where this page comes from
- ubuntu stonking: erlang-doc 1:29.0.6+dfsg-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms