From 32b9d6a38c81bc57baf496c0987f4e061a0cfe91 Mon Sep 17 00:00:00 2001 From: Kirill Likhodedov Date: Mon, 5 Apr 2021 11:17:04 +0300 Subject: [PATCH] trusted-projects: expand ~ as the user home: IDEA-265821 GitOrigin-RevId: 7e7502300386e15fe2f029ae8bcc150d0bab411f --- .../src/com/intellij/ide/impl/TrustedHostsConfigurable.kt | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/platform/platform-impl/src/com/intellij/ide/impl/TrustedHostsConfigurable.kt b/platform/platform-impl/src/com/intellij/ide/impl/TrustedHostsConfigurable.kt index a0eb738a3d9f..a07a933d5272 100644 --- a/platform/platform-impl/src/com/intellij/ide/impl/TrustedHostsConfigurable.kt +++ b/platform/platform-impl/src/com/intellij/ide/impl/TrustedHostsConfigurable.kt @@ -11,6 +11,7 @@ import com.intellij.openapi.ui.DialogBuilder import com.intellij.openapi.ui.DialogPanel import com.intellij.openapi.ui.Messages import com.intellij.openapi.ui.TextFieldWithBrowseButton +import com.intellij.openapi.util.io.FileUtil import com.intellij.ui.CollectionListModel import com.intellij.ui.ToolbarDecorator import com.intellij.ui.components.JBList @@ -87,7 +88,7 @@ class TrustedHostsConfigurable : BoundConfigurable(IdeBundle.message("configurab .title(IdeBundle.message("trusted.hosts.settings.new.trusted.folder.dialog.title")) .setNorthPanel(pathField) .showAndGet() - return if (ok) pathField.text else null + return if (ok) FileUtil.expandUserHome(pathField.text) else null } override fun getId(): String {