On 7/29/06, Niclas Hedhman <[EMAIL PROTECTED]> wrote:
>
> Hi,
>
> I am looking into which packages are used by Wicket (see below) and wonder why
> Swing is being used (javax.swing.text, javax.swing.event, javax.swing.tree)??


You probably mean why Swing is *not* being used? Swing is only used
for the tree. We aim - or at least Jonathan originally did - to depend
as much as we can on 'normal' models. Tree is a different beast
because of two things: there is no generic tree data structure in
java.util (arguably, there are a couple of things that represent
trees, but not in the way that would be useful for a component), and I
felt that Swing's tree model was very complete and fitted right in
with the kind of tree component I had in mind. The ability to reuse
the model between Swing and Wicket applications was only a minor
advantage to us really.

Most of the models and utility classes in Swing however are geared
towards drawing components on a screen, with positions, carets, paint
methods, etc. Furthermore, Swing generally works in a push way: you
use property change listeners etc to propagate model changes so that
components may redraw themselves, while Wicket being a web application
framework that works on request basis does not need that and simply
re-renders components when they are relevant for a new request (e.g.
the whole page with normal requests or the components in ajax request
target in ajax requests), pulling the fresh model values in the
process.

Hence, in most cases Wicket and Swing mismatch as they are to operate
in a different environment. Furthermore, we hope Wicket is still
pretty minimal in the core, so if you would need to have component
models that can operate in both environments it generally should be
easy to accomplish. And please send a note to this list for specific
problems you want to solve.

Eelco

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Wicket-develop mailing list
Wicket-develop@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to