if (category.equalsIgnoreCase("DEBUG")) { JOptionPane.showMessageDialog(gui, message + "\n\n" + details, title, JOptionPane.QUESTION_MESSAGE); } else if (category.equalsIgnoreCase("INFO")) { JOptionPane.showMessageDialog(gui, message + "\n\n" + details, title, JOptionPane.INFORMATION_MESSAGE); } else if (category.equalsIgnoreCase("MESSAGE")) { JOptionPane.showMessageDialog(gui, message + "\n\n" + details, title, JOptionPane.PLAIN_MESSAGE); } else if (category.equalsIgnoreCase("WARNING")) { JOptionPane.showMessageDialog(gui, message + "\n\n" + details, title, JOptionPane.WARNING_MESSAGE); } else { JOptionPane.showMessageDialog(gui, message + "\n\n" + details, title, JOptionPane.ERROR_MESSAGE); }
MessageDialogThread t = new MessageDialogThread(gui, accountId, category, title, message, details); t.start();
    public boolean showUserEvent(int accountId, String category, String title,            String message, String details) {        try {            if (category.equalsIgnoreCase("DEBUG")) {                JOptionPane.showMessageDialog(gui, message + "\n\n" + details,                        title, JOptionPane.QUESTION_MESSAGE);            } else if (category.equalsIgnoreCase("INFO")) {                JOptionPane.showMessageDialog(gui, message + "\n\n" + details,                        title, JOptionPane.INFORMATION_MESSAGE);            } else if (category.equalsIgnoreCase("MESSAGE")) {                JOptionPane.showMessageDialog(gui, message + "\n\n" + details,                        title, JOptionPane.PLAIN_MESSAGE);            } else if (category.equalsIgnoreCase("WARNING")) {                JOptionPane.showMessageDialog(gui, message + "\n\n" + details,                        title, JOptionPane.WARNING_MESSAGE);            } else {                JOptionPane.showMessageDialog(gui, message + "\n\n" + details,                        title, JOptionPane.ERROR_MESSAGE);            }            return true;        } catch (Exception e) {            {                e.printStackTrace();                return false;            }        }    }