mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-03 22:35:43 +02:00
[190010] fire finish event if finished or cancelled
This commit is contained in:
parent
6a25b7a149
commit
b6e59543b3
1 changed files with 7 additions and 2 deletions
|
@ -29,11 +29,13 @@ public class OutputRefresh implements Runnable
|
||||||
{
|
{
|
||||||
private IHostSearchResultConfiguration searchConfig;
|
private IHostSearchResultConfiguration searchConfig;
|
||||||
private boolean isDone = false;
|
private boolean isDone = false;
|
||||||
|
private boolean isCancelled = false;
|
||||||
|
|
||||||
public OutputRefresh(IHostSearchResultConfiguration searchConfig)
|
public OutputRefresh(IHostSearchResultConfiguration searchConfig)
|
||||||
{
|
{
|
||||||
this.searchConfig = searchConfig;
|
this.searchConfig = searchConfig;
|
||||||
this.isDone = searchConfig.getStatus() == IHostSearchConstants.FINISHED;
|
this.isDone = searchConfig.getStatus() == IHostSearchConstants.FINISHED;
|
||||||
|
this.isCancelled = searchConfig.getStatus() == IHostSearchConstants.CANCELLED;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void run() {
|
public void run() {
|
||||||
|
@ -42,11 +44,14 @@ public class OutputRefresh implements Runnable
|
||||||
{
|
{
|
||||||
ISystemRegistry registry = RSECorePlugin.getTheSystemRegistry();
|
ISystemRegistry registry = RSECorePlugin.getTheSystemRegistry();
|
||||||
registry.fireEvent(new SystemResourceChangeEvent(searchConfig, ISystemResourceChangeEvents.EVENT_REFRESH, null));
|
registry.fireEvent(new SystemResourceChangeEvent(searchConfig, ISystemResourceChangeEvents.EVENT_REFRESH, null));
|
||||||
|
|
||||||
if (isDone)
|
if (isDone || isCancelled)
|
||||||
{
|
{
|
||||||
registry.fireEvent(new SystemResourceChangeEvent(searchConfig, ISystemResourceChangeEvents.EVENT_SEARCH_FINISHED, null));
|
registry.fireEvent(new SystemResourceChangeEvent(searchConfig, ISystemResourceChangeEvents.EVENT_SEARCH_FINISHED, null));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
Loading…
Add table
Reference in a new issue