fun showOptionalMessage()

in bunch-cli/src/main/kotlin/org/jetbrains/bunches/hooks/dependentOutput.kt [8:24]


fun showOptionalMessage(
    message: String,
    options: Array<String>,
    initialValue: String,
    parent: Component? = null
): Int {
    val area = JTextArea()
    area.isEditable = false
    area.text = message
    area.isOpaque = false

    return JOptionPane.showOptionDialog(
        parent, area, "Bunch Tool Warning",
        JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE, null,
        options, initialValue
    )
}