Hi!
Getting warm with Java this week, I have learned that the usage of
Swing is highly recommended. I have seen many examples up to now, most
of them actually preferring Swing. However, I wonder why all of them
implement the old-fashioned (is it really?) AWT-only eventListener.
Why is this? Is something wrong with javax.swing.event ?
Sincerly,
S.T.
Joshua Cranmer - 24 May 2007 23:53 GMT
> Hi!
>
[quoted text clipped - 7 lines]
>
> S.T.
Look at the classes in javax.swing.event... How many of them implement
basic functionality like MouseMove, etc.? Zero. The events in
javax.swing.event are those that are specific to Swing, like JTables or
JLists; the most commonly needed events are stored in java.awt.event.
Besides, the java.awt.event is NOT AWT-only; all Swing components are
really AWT components, so there was no sense in duplicating an entire
event hierarchy because of the addition of Swing.
S.T - 25 May 2007 01:10 GMT
Dear Joshua,
thank you very much for your precise answer. Now the usage of AWT
eventListeners with Swing makes sense to me.
Sincerly
S.T.