Mercurial > hg > xemacs-beta
comparison lwlib/lwlib-utils.c @ 398:74fd4e045ea6 r21-2-29
Import from CVS: tag r21-2-29
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:13:30 +0200 |
parents | 5a88923fcbfe |
children | 697ef44129c6 |
comparison
equal
deleted
inserted
replaced
397:f4aeb21a5bad | 398:74fd4e045ea6 |
---|---|
28 | 28 |
29 #include <X11/Xatom.h> | 29 #include <X11/Xatom.h> |
30 #include <X11/IntrinsicP.h> | 30 #include <X11/IntrinsicP.h> |
31 #include <X11/ObjectP.h> | 31 #include <X11/ObjectP.h> |
32 #include "lwlib-utils.h" | 32 #include "lwlib-utils.h" |
33 | |
34 void | |
35 destroy_all_children (Widget widget) | |
36 { | |
37 Widget* children; | |
38 unsigned int number; | |
39 int i; | |
40 | |
41 children = XtCompositeChildren (widget, &number); | |
42 if (children) | |
43 { | |
44 /* Unmanage all children and destroy them. They will only be | |
45 * really destroyed when we get out of DispatchEvent. */ | |
46 for (i = 0; i < number; i++) | |
47 { | |
48 Widget child = children [i]; | |
49 if (!child->core.being_destroyed) | |
50 { | |
51 XtUnmanageChild (child); | |
52 XtDestroyWidget (child); | |
53 } | |
54 } | |
55 XtFree ((char *) children); | |
56 } | |
57 } | |
33 | 58 |
34 /* Redisplay the contents of the widget, without first clearing it. */ | 59 /* Redisplay the contents of the widget, without first clearing it. */ |
35 void | 60 void |
36 XtNoClearRefreshWidget (Widget widget) | 61 XtNoClearRefreshWidget (Widget widget) |
37 { | 62 { |