Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 372686 - [LML] "Widget is disposed" updating status bar; UI freezes
Summary: [LML] "Widget is disposed" updating status bar; UI freezes
Status: CLOSED FIXED
Alias: None
Product: PTP
Classification: Tools
Component: RM (show other bugs)
Version: 6.0   Edit
Hardware: Macintosh Mac OS X
: P3 major (vote)
Target Milestone: 6.0   Edit
Assignee: Carsten Karbach CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-02-27 16:40 EST by Jeffrey Overbey CLA
Modified: 2013-02-28 03:29 EST (History)
2 users (show)

See Also:


Attachments
This patch should solve the problem. Your solution worked. The usagebar tried to repaint, although it was already disposed. (807 bytes, patch)
2012-03-02 04:15 EST, Carsten Karbach CLA
g.watson: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jeffrey Overbey CLA 2012-02-27 16:40:53 EST
I'm not exactly certain what I'm doing to cause this, but LML is occasionally giving me the following exception.  (I'm using the TORQUE-ALPS driver, if that matters.)  The only problem is that, when this happens, the entire Eclipse UI locks up (the mouse cursor turns into the Mac OS X "spinning beach ball of death" and never recovers), and so I have to kill and restart Eclipse.

Let me know what else I can do to help; sorry I don't have a better idea of how to reproduce this.  I'm hoping that adding "if (!widget.isDisposed()) { ... }" to the code will take care of the problem.

!ENTRY org.eclipse.ui 4 0 2012-02-27 15:30:34.009
!MESSAGE Unhandled event loop exception
!STACK 0
org.eclipse.swt.SWTException: Widget is disposed
	at org.eclipse.swt.SWT.error(SWT.java:4300)
	at org.eclipse.swt.SWT.error(SWT.java:4215)
	at org.eclipse.swt.SWT.error(SWT.java:4186)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:774)
	at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:568)
	at org.eclipse.swt.widgets.Control.redraw(Control.java:2738)
	at org.eclipse.ptp.rm.lml.ui.providers.Usagebar.updateStatus(Usagebar.java:227)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.informAll(ObjectStatus.java:369)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.justMouseover(ObjectStatus.java:393)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.mouseOver(ObjectStatus.java:282)
	at org.eclipse.ptp.rm.lml.ui.providers.support.MouseInteraction.mouseMoveAction(MouseInteraction.java:137)
	at org.eclipse.ptp.rm.lml.ui.providers.Usagebar$1.mouseMove(Usagebar.java:108)
	at org.eclipse.swt.widgets.TypedListener.handleEvent(TypedListener.java:211)
	...


!ENTRY org.eclipse.ui 4 0 2012-02-27 15:30:34.309
!MESSAGE Unhandled event loop exception
!STACK 0
org.eclipse.swt.SWTException: Widget is disposed
	at org.eclipse.swt.SWT.error(SWT.java:4300)
	at org.eclipse.swt.SWT.error(SWT.java:4215)
	at org.eclipse.swt.SWT.error(SWT.java:4186)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:774)
	at org.eclipse.swt.widgets.Widget.checkWidget(Widget.java:568)
	at org.eclipse.swt.widgets.Control.redraw(Control.java:2738)
	at org.eclipse.ptp.rm.lml.ui.providers.Usagebar.updateStatus(Usagebar.java:227)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.informAll(ObjectStatus.java:369)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.mouseexit(ObjectStatus.java:232)
	at org.eclipse.ptp.rm.lml.internal.core.model.ObjectStatus.mouseExitLast(ObjectStatus.java:253)
	at org.eclipse.ptp.rm.lml.ui.providers.support.MouseInteraction.mouseExitAction(MouseInteraction.java:104)
	at org.eclipse.ptp.rm.lml.ui.providers.Usagebar$3.handleEvent(Usagebar.java:151)
	at org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java:84)
	...
Comment 1 Jeffrey Overbey CLA 2012-02-27 16:41:30 EST
I should have mentioned, I'm using the latest PTP code from the master branch.
Comment 2 Carsten Karbach CLA 2012-03-02 04:15:27 EST
Created attachment 211944 [details]
This patch should solve the problem. Your solution worked. The usagebar tried to repaint, although it was already disposed.
Comment 3 Carsten Karbach CLA 2012-03-12 05:54:47 EDT
I confirm the following:

(a) I wrote 100% of the code without incorporating content from elsewhere or
relying on the intellectual property of others.

(b) I have the right to contribute the code to Eclipse.

(c) I have included the EPL license header in all source files.