mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
[kotlin] Remove extra slash before file name
#KTIJ-27845 GitOrigin-RevId: 429ca0ee9a9b66ff6ed9185826d39c49ffa8b924
This commit is contained in:
committed by
intellij-monorepo-bot
parent
d70f43e027
commit
d193e1d34c
+2
-2
@@ -99,9 +99,9 @@ sealed interface K2MoveTargetModel {
|
||||
fun updateFileChooser() {
|
||||
val itemWrapper = (destinationChooser.comboBox.selectedItem as? DirectoryChooser.ItemWrapper) ?: return
|
||||
val existingPath = itemWrapper.directory?.virtualFile?.path ?: return
|
||||
val postFix = itemWrapper.postfix?.removePrefix("\\") ?: "" // post fix in case real directory doesn't exist yet
|
||||
val postFix = itemWrapper.postfix?.removePrefix("\\")?.replace("\\", "/")?.plus("/") ?: "" // post fix in case real directory doesn't exist yet
|
||||
val fileName = fileChooser.text.substringAfterLast("/")
|
||||
val fullPath = "$existingPath/$postFix/$fileName"
|
||||
val fullPath = "$existingPath/$postFix$fileName"
|
||||
if (fullPath != fileChooser.text) fileChooser.text = fullPath
|
||||
}
|
||||
destinationChooser.comboBox.addActionListener {
|
||||
|
||||
Reference in New Issue
Block a user