mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-04-29 19:45:01 +02:00
[241024] - [view model] Most views stop refereshing after a breakpoint hit after a long operation (e.g. sleep)
This commit is contained in:
parent
bc15b2355b
commit
0006e4ba15
3 changed files with 27 additions and 0 deletions
|
@ -566,9 +566,21 @@ abstract public class AbstractVMProvider implements IVMProvider, IVMEventListene
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (proxy == null) {
|
||||
proxy = createModelProxyStrategy(element);
|
||||
getActiveModelProxies().add(proxy);
|
||||
} else if (proxy.isDisposed()) {
|
||||
// DSF is capable of re-using old proxies which were previously
|
||||
// disposed. However, the viewer which installs a proxy using
|
||||
// a background job to install the proxy calls
|
||||
// IModelProxy.isDisposed(), to check whether the proxy was disposed
|
||||
// before it could be installed. We need to clear the disposed flag
|
||||
// of the re-used proxy here, otherwise the proxy will never get used.
|
||||
// Calling init here will cause the init() method to be called twice
|
||||
// so the IVMModelProxy needs to be prepared for that.
|
||||
// See bug 241024.
|
||||
proxy.init(context);
|
||||
}
|
||||
return proxy;
|
||||
}
|
||||
|
|
|
@ -18,6 +18,9 @@ import org.eclipse.debug.internal.ui.viewers.model.provisional.IModelProxy;
|
|||
* View Model extension to the platform IModelProxy interface. This extension
|
||||
* allows the IVMProvider implementation to delegate the model proxy implementation
|
||||
* into a separate object.
|
||||
* <br/>
|
||||
* Note: The IVMModelProxy.init() may be called twice when installed, as a
|
||||
* workaround for bug 241024.
|
||||
*/
|
||||
@SuppressWarnings("restriction")
|
||||
public interface IVMModelProxy extends IModelProxy {
|
||||
|
|
|
@ -601,11 +601,23 @@ public class AbstractCachingVMProvider extends AbstractVMProvider implements ICa
|
|||
IVMModelProxy next = itr.next();
|
||||
if (next != null && next.getRootElement().equals(element)) {
|
||||
proxy = next;
|
||||
break;
|
||||
}
|
||||
}
|
||||
if (proxy == null) {
|
||||
proxy = createModelProxyStrategy(element);
|
||||
getActiveModelProxies().add(proxy);
|
||||
} else if (proxy.isDisposed()) {
|
||||
// DSF is capable of re-using old proxies which were previously
|
||||
// disposed. However, the viewer which installs a proxy using
|
||||
// a background job to install the proxy calls
|
||||
// IModelProxy.isDisposed(), to check whether the proxy was disposed
|
||||
// before it could be installed. We need to clear the disposed flag
|
||||
// of the re-used proxy here, otherwise the proxy will never get used.
|
||||
// Calling init here will cause the init() method to be called twice
|
||||
// so the IVMModelProxy needs to be prepared for that.
|
||||
// See bug 241024.
|
||||
proxy.init(context);
|
||||
}
|
||||
return proxy;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue