From ffe3cf63304d93246302678d9fd44c3c70b80934 Mon Sep 17 00:00:00 2001 From: irengrig Date: Tue, 24 May 2011 19:05:07 +0400 Subject: [PATCH] git log: sometimes it forgets to refresh (due to stopping previous task) -> fixed --- .../git4idea/history/wholeTree/LoadController.java | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/plugins/git4idea/src/git4idea/history/wholeTree/LoadController.java b/plugins/git4idea/src/git4idea/history/wholeTree/LoadController.java index e017e6cf73a7..b8589c22912d 100644 --- a/plugins/git4idea/src/git4idea/history/wholeTree/LoadController.java +++ b/plugins/git4idea/src/git4idea/history/wholeTree/LoadController.java @@ -81,16 +81,15 @@ public class LoadController implements Loader { myUsersComponent.acceptUpdate(myUsersIndex.getKeys()); - final Continuation continuation; if (myPreviousAlgorithm != null) { - continuation = myPreviousAlgorithm.getContinuation(); - continuation.clearQueue(); - } else { - continuation = Continuation.createFragmented(myProject, true); + final Continuation oldContinuation = myPreviousAlgorithm.getContinuation(); + oldContinuation.cancelCurrent(); + oldContinuation.clearQueue(); } + + final Continuation continuation = Continuation.createFragmented(myProject, true); myPreviousAlgorithm = new LoadAlgorithm(myProject, list, shortLoaders, continuation); myPreviousAlgorithm.fillContinuation(); - continuation.cancelCurrent(); continuation.resume(); }