Warning: main(/www/www/htdocs/style/globals.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 1
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/globals.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 1
Warning: main(/www/www/htdocs/style/header.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 8
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/header.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 8
Remove a widget from the widget family hierarchy
int PtDestroyWidget( PtWidget_t *widget );
ph
This function performs the following on the specified
widget:
- unrealizes it, if necessary
- destroys its children
- removes it from the widget family hierarchy
- flags it for destruction by adding it to the destroyed list.
The widget's resources aren't freed until the return of
PtEventHandler().
|
You might get callbacks from the widget after PtDestroyWidget() has
returned.
To determine if this is happening, check the widget's
Pt_DESTROYED flag.
For example:
if (PtWidgetFlags(widget) & Pt_DESTROYED)
{
return( Pt_CONTINUE );
}
|
- 0
- Success.
- -1
- An error occurred.
See
PtContainerBox().
Photon
Safety: | |
Interrupt handler |
No |
Signal handler |
No |
Thread |
No |
PtEventHandler(),
PtCreateWidget(),
PtRealizeWidget(),
PtUnrealizeWidget(),
PtWidgetFlags()
Pt_ARG_FLAGS,
Pt_CB_DESTROYED,
Pt_CB_IS_DESTROYED
resources of PtWidget in the Widget Reference
“Widget life cycle”
in the Introduction to the Photon Programmer's Guide
Warning: main(/www/www/htdocs/style/footer.php) [function.main]: failed to open stream: No such file or directory in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 146
Warning: main() [function.include]: Failed opening '/www/www/htdocs/style/footer.php' for inclusion (include_path='.:/www/www/common:/www/www/php/lib/php') in /www/www/docs/6.4.1/photon/lib_ref/pt/ptdestroywidget.html on line 146