mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-187101 vcs: reset excluded changes after partial commit with "Create Patch"
This commit is contained in:
@@ -119,6 +119,7 @@
|
||||
<openapi.vcs.actions.AnnotateToggleAction.Provider implementation="com.intellij.openapi.vcs.actions.AnnotateVcsVirtualFileAction$Provider"/>
|
||||
<openapi.vcs.actions.AnnotateToggleAction.Provider implementation="com.intellij.openapi.vcs.actions.AnnotateDiffViewerAction$Provider" order="first"/>
|
||||
|
||||
<checkinHandlerFactory implementation="com.intellij.openapi.vcs.impl.LineStatusTrackerManager$CheckinFactory"/>
|
||||
<ignoredFileProvider implementation="com.intellij.openapi.vcs.changes.ChangeListManagerImpl$DefaultIgnoredFileProvider" order="last"/>
|
||||
<ignoredFileProvider implementation="com.intellij.configurationStore.vcs.StoreIgnoredFileProvider"/>
|
||||
</extensions>
|
||||
|
||||
@@ -37,7 +37,6 @@ import com.intellij.openapi.vcs.changes.actions.MoveChangesToAnotherListAction;
|
||||
import com.intellij.openapi.vcs.changes.committed.CommittedChangesCache;
|
||||
import com.intellij.openapi.vcs.checkin.CheckinEnvironment;
|
||||
import com.intellij.openapi.vcs.checkin.CheckinHandler;
|
||||
import com.intellij.openapi.vcs.impl.LineStatusTrackerManager;
|
||||
import com.intellij.openapi.vcs.update.RefreshVFsSynchronously;
|
||||
import com.intellij.openapi.vfs.VirtualFile;
|
||||
import com.intellij.util.ExceptionUtil;
|
||||
@@ -139,7 +138,6 @@ public class CommitHelper {
|
||||
delegateCommitToVcsThread();
|
||||
}
|
||||
finally {
|
||||
LineStatusTrackerManager.getInstanceImpl(myProject).resetExcludedFromCommitMarkers();
|
||||
vcsManager.stopBackgroundVcsOperation();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -50,6 +50,8 @@ import com.intellij.openapi.vcs.*
|
||||
import com.intellij.openapi.vcs.changes.*
|
||||
import com.intellij.openapi.vcs.changes.conflicts.ChangelistConflictFileStatusProvider
|
||||
import com.intellij.openapi.vcs.changes.ui.ChangesViewContentManager
|
||||
import com.intellij.openapi.vcs.checkin.CheckinHandler
|
||||
import com.intellij.openapi.vcs.checkin.CheckinHandlerFactory
|
||||
import com.intellij.openapi.vcs.ex.LineStatusTracker
|
||||
import com.intellij.openapi.vcs.ex.PartialLocalLineStatusTracker
|
||||
import com.intellij.openapi.vcs.ex.SimpleLocalLineStatusTracker
|
||||
@@ -711,6 +713,24 @@ class LineStatusTrackerManager(
|
||||
}
|
||||
}
|
||||
|
||||
class CheckinFactory : CheckinHandlerFactory() {
|
||||
override fun createHandler(panel: CheckinProjectPanel, commitContext: CommitContext): CheckinHandler {
|
||||
return object : CheckinHandler() {
|
||||
override fun checkinSuccessful() {
|
||||
runInEdt {
|
||||
getInstanceImpl(panel.project).resetExcludedFromCommitMarkers()
|
||||
}
|
||||
}
|
||||
|
||||
override fun checkinFailed(exception: MutableList<VcsException>?) {
|
||||
runInEdt {
|
||||
getInstanceImpl(panel.project).resetExcludedFromCommitMarkers()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private fun shouldBeUpdated(oldInfo: ContentInfo?, newInfo: ContentInfo): Boolean {
|
||||
if (oldInfo == null) return true
|
||||
|
||||
Reference in New Issue
Block a user