Java JOptionPane Confirmation confirmAction(Component comp, String title, String msg)

Here you can find the source of confirmAction(Component comp, String title, String msg)

Description

confirm Action

License

Open Source License

Declaration

public static boolean confirmAction(Component comp, String title, String msg) 

Method Source Code


//package com.java2s;
//License from project: Open Source License 

import java.awt.Component;

import javax.swing.JOptionPane;

public class Main {
    public static boolean confirmAction(Component comp, String title, String msg) {
        int decision = JOptionPane.showConfirmDialog(comp, msg, title, JOptionPane.YES_NO_OPTION,
                JOptionPane.WARNING_MESSAGE);
        if (decision == JOptionPane.NO_OPTION) {
            return false;
        }//www  . java  2 s.  com
        return true;
    }
}

Related

  1. confirm(String message)
  2. confirm(String message, boolean typeYesNo)
  3. confirm(String message, String title)
  4. confirm(String msg)
  5. confirm(String title, Object message, JComponent parent)
  6. confirmarEliminar(Component component, String titulo, String mensaje)
  7. confirmationBox(String msg, String title)
  8. confirmationPrompt(String msg, String title, Component parent)
  9. confirmChangeReference(boolean isChangingProject)