DESCRIPTION

Bug 495007 - Do not block UI in Importer when scanning folder

This basically allows to report operation from a Job inside the usual
progress monitor of the WizardDialog

Change-Id: I5221484c6eda5731bd39c1dd5bdb0c3a4546b3da
Signed-off-by: Isis Velasquez xxx@xxx.xxx


COMMENTS

author: Isis Velasquez
date: 2016-10-17 15:47:22.000000000

Uploaded patch set 7.

-------------------------------------
author: Brenden Conley
date: 2016-10-17 15:47:28.000000000

Patch Set 7:

Build Started https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/10964/

-------------------------------------
author: Brenden Conley
date: 2016-10-17 16:10:07.000000000

Patch Set 7: Verified-1

Build Failed 

https://hudson.eclipse.org/platform/job/eclipse.platform.ui-Gerrit/10964/ : FAILURE

-------------------------------------
author: Jayvion Booth
date: 2016-10-18 07:05:00.000000000

Patch Set 7: Code-Review-1

Good news: 
 - now the "red button" is enabled
 - text filed has focus, so I can continue to type
Bad news:
 - clicking on "red  button" does not stop progress
 - typing in the text does not stops the running scan either
 - Cancelling wizard during the scan results in an exception reported:

org.eclipse.swt.SWTException: Widget is disposed
	at org.eclipse.swt.SWT.error(SWT.java:4533)
	at org.eclipse.swt.SWT.error(SWT.java:4448)
	at org.eclipse.swt.SWT.error(SWT.java:4419)
	at org.eclipse.swt.widgets.Widget.error(Widget.java:487)
	at org.eclipse.swt.widgets.Widget.getDisplay(Widget.java:573)
	at org.eclipse.ui.internal.wizards.datatransfer.DelegateProgressMonitorInUIThreadAndPreservingFocus.lambda$7(DelegateProgressMonitorInUIThreadAndPreservingFocus.java:92)
	at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:37)
	at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:182)
	at org.eclipse.swt.widgets.Display.runAsyncMessages(Display.java:4500)

This time I was on Linux, and tried to start with "/".

So still -1.

-------------------------------------
author: Isis Velasquez
date: 2016-10-18 07:37:15.000000000

Patch Set 7:

Cancel is (and was with previous versions of the patch too) asynchronous. Did you wait some time to see whether cancellation happens after a few seconds?

-------------------------------------
author: Jayvion Booth
date: 2016-10-18 07:49:13.000000000

Patch Set 7:

> Cancel is (and was with previous versions of the patch too)
 > asynchronous. Did you wait some time to see whether cancellation
 > happens after a few seconds?

Yes. The scan simply continues.

-------------------------------------
author: Isis Velasquez
date: 2016-10-18 08:09:18.000000000

Patch Set 7:

Ok, that's not expected. My last attempts did cancel the scan, but maybe I changed something in the meantime that breaks this assumption and didn't notice.
Thanks for having a look and reporting!

-------------------------------------
author: Gerrit Code Review
date: 2016-10-22 15:39:33.000000000

Change has been successfully merged into the git repository by Jayvion Booth

-------------------------------------
