You don't specify which event object you mean. However, all events which derive from java.awt.event.ComponentEvent have a getComponent() method which returns the java.awt.Component instance of the originating component.
This could have been easily discovered by using the Java API Docs which are freely available from Sun. If you are writing anything more than a trivial application in Java I recommend you obtain this and become familiar with its use.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.