[github] Preselection and focus in select github account dialog

This commit is contained in:
Ivan Semenov
2018-07-27 18:51:19 +03:00
parent b51212d660
commit b0481e8b3d
@@ -58,6 +58,7 @@ class GithubChooseAccountDialog(project: Project?, parentComponent: JComponent?,
this.title = title
setOKButtonText(okText)
init()
accountsList.selectedIndex = 0
}
override fun doValidate(): ValidationInfo? {
@@ -74,4 +75,6 @@ class GithubChooseAccountDialog(project: Project?, parentComponent: JComponent?,
.addToCenter(JBScrollPane(accountsList).apply { preferredSize = JBDimension(150, 80) })
.apply { setDefaultCheckBox?.run(::addToBottom) }
}
override fun getPreferredFocusedComponent() = accountsList
}