Remove 182 support

#KT-33536 Fixed
This commit is contained in:
Nikolay Krasko
2019-08-27 18:02:21 +03:00
parent 1c4ee6bd79
commit 4d0fc1dc22
58 changed files with 0 additions and 5317 deletions
@@ -1,46 +0,0 @@
/*
* Copyright 2010-2018 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.git
import com.intellij.openapi.project.Project
import com.intellij.openapi.vcs.FilePath
import git4idea.checkin.GitCheckinExplicitMovementProvider
import org.jetbrains.kotlin.idea.actions.pathBeforeJ2K
import java.util.*
class KotlinExplicitMovementProvider : GitCheckinExplicitMovementProvider() {
override fun isEnabled(project: Project): Boolean {
return true
}
override fun getDescription(): String {
return "Extra commit for .java > .kt renames"
}
override fun getCommitMessage(oldCommitMessage: String): String {
return "Rename .java to .kt"
}
override fun collectExplicitMovements(
project: Project,
beforePaths: List<FilePath>,
afterPaths: List<FilePath>
): Collection<GitCheckinExplicitMovementProvider.Movement> {
val movedChanges = ArrayList<GitCheckinExplicitMovementProvider.Movement>()
for (after in afterPaths) {
val pathBeforeJ2K = after.virtualFile?.pathBeforeJ2K
if (pathBeforeJ2K != null) {
val before = beforePaths.firstOrNull { it.path == pathBeforeJ2K }
if (before != null) {
movedChanges.add(GitCheckinExplicitMovementProvider.Movement(before, after))
after.virtualFile?.pathBeforeJ2K = null
}
}
}
return movedChanges
}
}