KT-27869: Make Java to Kotlin dialog show yes/no button according to it's question

* Change `showOkCancelDialog` to `showYesNoDialog`
 #KT-27869 Fixed
This commit is contained in:
Burak Eregar
2019-01-25 15:53:35 +00:00
committed by Simon Ogorodnik
parent ef48373109
commit 91980c5293
3 changed files with 3 additions and 3 deletions
@@ -131,7 +131,7 @@ class JavaToKotlinAction : AnAction() {
if (enableExternalCodeProcessing && converterResult!!.externalCodeProcessing != null) {
val question = "Some code in the rest of your project may require corrections after performing this conversion. Do you want to find such code and correct it too?"
if (!askExternalCodeProcessing || (Messages.showOkCancelDialog(project, question, title, Messages.getQuestionIcon()) == Messages.OK)) {
if (!askExternalCodeProcessing || (Messages.showYesNoDialog(project, question, title, Messages.getQuestionIcon()) == Messages.YES)) {
ProgressManager.getInstance().runProcessWithProgressSynchronously(
{
runReadAction {
@@ -126,7 +126,7 @@ class JavaToKotlinAction : AnAction() {
if (enableExternalCodeProcessing && converterResult!!.externalCodeProcessing != null) {
val question = "Some code in the rest of your project may require corrections after performing this conversion. Do you want to find such code and correct it too?"
if (!askExternalCodeProcessing || (Messages.showOkCancelDialog(project, question, title, Messages.getQuestionIcon()) == Messages.OK)) {
if (!askExternalCodeProcessing || (Messages.showYesNoDialog(project, question, title, Messages.getQuestionIcon()) == Messages.YES)) {
ProgressManager.getInstance().runProcessWithProgressSynchronously(
{
runReadAction {
@@ -125,7 +125,7 @@ class JavaToKotlinAction : AnAction() {
if (enableExternalCodeProcessing && converterResult!!.externalCodeProcessing != null) {
val question = "Some code in the rest of your project may require corrections after performing this conversion. Do you want to find such code and correct it too?"
if (!askExternalCodeProcessing || (Messages.showOkCancelDialog(project, question, title, Messages.getQuestionIcon()) == Messages.OK)) {
if (!askExternalCodeProcessing || (Messages.showYesNoDialog(project, question, title, Messages.getQuestionIcon()) == Messages.YES)) {
ProgressManager.getInstance().runProcessWithProgressSynchronously(
{
runReadAction {