This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Any ideas on lightweight component support (probably important for swing)?
"Scott Gilbertson" <scottg at mantatest dot com> writes:
> > scott > I therefore figured we needed to make LightweightPeer an
> extension
> > scott > of ContainerPeer (rather than ComponentPeer) and return a
> > scott > LightweightPeer from createComponent.
> brian > I think this is wrong. A LightweightPeer is not necessarily a
> brian > container, though you may implement a container based upon one.
>
> In that case, where does java.awt.Container get its peer in the
> lightweight case? There is no createContainer method in
> java.awt.Toolkit. Should Container create its peer directly
> (without using Toolkit)?
It's the same peer, i.e. we don't implement a peer specifically for
Container, the one provided for Component does just fine. The extra
functionality of maintaining a sequence of added children is just that
and not part of the peer.
Brian
--
Brian Jones <cbj at gnu dot org>