public void DoTaskOnIdle(int msDelay) {
AssertIsMainThread();
Debug.Assert(!IsDisposed);
if (_taskAction == null)
throw new InvalidOperationException("Task action is null");
_delay = msDelay;
ConnectToIdle();
}
IdleTimeAsyncTask::DoTaskOnIdle ( ) : void | |
IdleTimeAsyncTask::DoTaskOnIdle ( Func |
protected OutlineRegionBuilder(ITextBuffer textBuffer, IEditorShell editorShell) { CurrentRegions = new OutlineRegionCollection(0); TextBuffer = textBuffer; TextBuffer.Changed += OnTextBufferChanged; BackgroundTask = new IdleTimeAsyncTask(TaskAction, MainThreadAction, editorShell); if (IsEnabled) { BackgroundTask.DoTaskOnIdle(300); } }