1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-09 10:05:24 +02:00

[164118] move cancelled check til after done check

This commit is contained in:
David McKnight 2006-12-06 15:43:50 +00:00
parent d9a0758560
commit acb5496c7b

View file

@ -287,15 +287,17 @@ public class DStoreStatusMonitor implements IDomainListener
// Current thread is UI thread // Current thread is UI thread
while (_workingStatuses.contains(status)) while (_workingStatuses.contains(status))
{ {
// while (display.readAndDispatch()) { /*
while (display.readAndDispatch()) {
//Process everything on event queue //Process everything on event queue
// } }
if ((monitor != null) && (monitor.isCanceled())) if ((monitor != null) && (monitor.isCanceled()))
{ {
setCancelled(status); setCancelled(status);
throw new InterruptedException(); throw new InterruptedException();
} }
*/
boolean statusDone = determineStatusDone(status); boolean statusDone = determineStatusDone(status);
@ -331,21 +333,19 @@ public class DStoreStatusMonitor implements IDomainListener
// Current thread is not UI thread // Current thread is not UI thread
while (_workingStatuses.contains(status)) while (_workingStatuses.contains(status))
{ {
if ((monitor != null) && (monitor.isCanceled()))
{
setCancelled(status);
throw new InterruptedException();
}
boolean statusDone = determineStatusDone(status); boolean statusDone = determineStatusDone(status);
if (statusDone)
if (statusDone)
{ {
setDone(status); setDone(status);
} }
else else
{ {
if ((monitor != null) && (monitor.isCanceled()))
{
setCancelled(status);
throw new InterruptedException();
}
waitForUpdate(); waitForUpdate();
//Thread.sleep(200); //Thread.sleep(200);