Corrected the JavaDoc of Widget#doAttach/DetachChildren() to reflect its actual usage. The old comment stated that all implementors of HasWidgets must override it. In fact, it only needs to be overridden if a child widget is physically but not logically attached to a parent. Patch by: jlabanca Review by: sumitchandel git-svn-id: https://google-web-toolkit.googlecode.com/svn/releases/1.6@4377 8db76d5a-ed1c-0410-87a9-c151d255dfc7
diff --git a/user/src/com/google/gwt/user/client/ui/Widget.java b/user/src/com/google/gwt/user/client/ui/Widget.java index 7d0725e..7f23170 100644 --- a/user/src/com/google/gwt/user/client/ui/Widget.java +++ b/user/src/com/google/gwt/user/client/ui/Widget.java
@@ -183,19 +183,23 @@ } /** - * If a widget implements HasWidgets, it must override this method and call - * {@link #onAttach()} for each of its child widgets. + * If a widget contains one or more child widgets that are not in the logical + * widget hierarchy (the child is physically connected only on the DOM level), + * it must override this method and call {@link #onAttach()} for each of its + * child widgets. * - * @see Panel#onAttach() + * @see #onAttach() */ protected void doAttachChildren() { } /** - * If a widget implements HasWidgets, it must override this method and call - * onDetach() for each of its child widgets. + * If a widget contains one or more child widgets that are not in the logical + * widget hierarchy (the child is physically connected only on the DOM level), + * it must override this method and call {@link #onDetach()} for each of its + * child widgets. * - * @see Panel#onDetach() + * @see #onDetach() */ protected void doDetachChildren() { }