<AWT Dev> <Swing Dev> Review request #3: 6852592 (revalidate() must be smarter)

Christopher Deckers chrriis at gmail.com
Thu Jul 23 13:10:31 PDT 2009

Hi Anthony,

> Applets always have a parent: it's either an embedded frame on the web-page,
> or your own container (such as a JFrame, or whatever). So this condition is
> not going to work as we would like it to.

If I understand correctly, the logical validate root in case of the
browser is the browser frame, not really the applet. The applet is
just a container that can be placed in a web browser and I don't see
why it would have a different treatment than a Panel for example.
I can understand we don't have a handle to the Window object
containing the applet so we can't really call validate(), hence this
work around.

This is mostly a conceptual discussion, as I said I don't really care
about the outcome for the Applet case :)

Slightly off-topic feature: wouldn't it be conceptually possible to
have a special parameter in the applet tag that specifies to use the
preferred size rather than an hardcoded size? That way applet that
declare not being validate roots would really be like any other HTML
elements and would automatically resize following
invalidation/validation cycles. This would also be useful if an applet
has a size that cannot be hardcoded (depending on font sizes or


More information about the awt-dev mailing list