diff --git a/src/main/java/com/cys4/sensitivediscoverer/ui/RegexEditDialog.java b/src/main/java/com/cys4/sensitivediscoverer/ui/RegexEditDialog.java index 0ce29ca..893ea30 100644 --- a/src/main/java/com/cys4/sensitivediscoverer/ui/RegexEditDialog.java +++ b/src/main/java/com/cys4/sensitivediscoverer/ui/RegexEditDialog.java @@ -163,7 +163,11 @@ public boolean showDialog(Component parentComponent, String dialogTitle) { sectionResBody.setSelected(defaults.contains(HttpSection.RES_BODY)); } - int returnValue = JOptionPane.showConfirmDialog(parentComponent, mainPanel, dialogTitle, JOptionPane.OK_CANCEL_OPTION); + int returnValue = JOptionPane.showConfirmDialog( + parentComponent, + mainPanel, + dialogTitle, + JOptionPane.OK_CANCEL_OPTION); if (returnValue != JOptionPane.OK_OPTION) return false; List sections = Arrays.asList( diff --git a/src/main/java/com/cys4/sensitivediscoverer/ui/RegexListPanel.java b/src/main/java/com/cys4/sensitivediscoverer/ui/RegexListPanel.java index 2ce32ae..aadc452 100644 --- a/src/main/java/com/cys4/sensitivediscoverer/ui/RegexListPanel.java +++ b/src/main/java/com/cys4/sensitivediscoverer/ui/RegexListPanel.java @@ -371,7 +371,7 @@ private JMenuItem createListClearMenuItem(List regexEntities, null, getLocaleString("options-list-clear-message"), getLocaleString("options-list-clear-title"), - JOptionPane.OK_CANCEL_OPTION); + JOptionPane.YES_NO_OPTION); if (dialogRes != JOptionPane.OK_OPTION) return; if (!regexEntities.isEmpty()) { @@ -394,7 +394,7 @@ private JMenuItem createListResetMenuItem(List regexEntities, null, getLocaleString("options-list-reset-message"), getLocaleString("options-list-reset-title"), - JOptionPane.OK_CANCEL_OPTION); + JOptionPane.YES_NO_OPTION); if (dialogRes != JOptionPane.OK_OPTION) return; if (!regexEntities.isEmpty()) { diff --git a/src/main/java/com/cys4/sensitivediscoverer/ui/tab/LoggerTab.java b/src/main/java/com/cys4/sensitivediscoverer/ui/tab/LoggerTab.java index 60bc347..a852043 100644 --- a/src/main/java/com/cys4/sensitivediscoverer/ui/tab/LoggerTab.java +++ b/src/main/java/com/cys4/sensitivediscoverer/ui/tab/LoggerTab.java @@ -509,7 +509,11 @@ private JToggleButton createExportLogsButton() { private JButton createClearLogsButton(JScrollPane scrollPaneLogger) { JButton btnClearLogs = new JButton(getLocaleString("logger-clearLogs-label")); btnClearLogs.addActionListener(e -> { - int dialog = JOptionPane.showConfirmDialog(null, getLocaleString("logger-clearLogs-confirm")); + int dialog = JOptionPane.showConfirmDialog( + null, + getLocaleString("logger-clearLogs-message"), + getLocaleString("logger-clearLogs-title"), + JOptionPane.YES_NO_OPTION); if (dialog == JOptionPane.YES_OPTION) { logEntriesManager.clear(); logsTableModel.fireTableDataChanged(); diff --git a/src/main/resources/TextUI_en_US.properties b/src/main/resources/TextUI_en_US.properties index 9eb389a..54a6e55 100644 --- a/src/main/resources/TextUI_en_US.properties +++ b/src/main/resources/TextUI_en_US.properties @@ -16,7 +16,8 @@ logger-analysis-start=Analyze HTTP History logger-analysis-stop=Stop analysis logger-analysis-stopping=Stopping the analysis... logger-clearLogs-label=Clear all logs -logger-clearLogs-confirm=Delete ALL the logs in the list? +logger-clearLogs-message=Delete ALL the logs in the list? +logger-clearLogs-title=Clear list? logger-exportLogs-label=Export list logs... logger-searchBar-label=Filter results: logger-resultsCount-label=Results: