Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Standard Widget Toolkit (SWT) » Do I need to remove listeners?
Do I need to remove listeners? [message #467595] Wed, 01 February 2006 16:59
Mike Higginbotham is currently offline Mike HigginbothamFriend
Messages: 22
Registered: July 2009
Junior Member
I am somewhat familiar with Swing and its lapsed listener problems. Does
SWT have the same or similar problem? My colleague is seeing leaked
listeners using Eclipse TPTP.

I put breakpoints in the Button.removeSelectionListener,
Widget.removeListener and Widget.removeDisposeListener methods as well
as the EventTable.unhook methods. I added a selection listener to a
button on my dialog. When I closed my dialog, none of the breakpoints
were reached. This tells me the listeners where not automatically
removed. Is this a problem? If not, why not? If so, why aren't listeners
automatically removed from controls like Button? Do I need to remove
listeners on my own by adding a dispose listener and while handling the
event remove all other listeners as well as the dispose listener?

Thanks,
Mike
Previous Topic:SWT object as ActiveX control - Revisited
Next Topic:Any simple example about inline text editing?
Goto Forum:
  


Current Time: Fri Nov 24 11:25:58 GMT 2017

Powered by FUDForum. Page generated in 0.03901 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software