JAL-4034 showConfirmDialog works for both desktop and jalviewjs
authorBen Soares <b.soares@dundee.ac.uk>
Tue, 12 Jul 2022 10:58:35 +0000 (11:58 +0100)
committerBen Soares <b.soares@dundee.ac.uk>
Tue, 12 Jul 2022 10:58:35 +0000 (11:58 +0100)
src/jalview/gui/StructureChooser.java

index a5fb2dd..9ff181b 100644 (file)
@@ -366,27 +366,12 @@ public class StructureChooser extends GStructureChooser
     // 'cancel' TODO: mock should be OK
     if (!runThread)
     {
-      int answer = JvOptionPane.showOptionDialog(this,
-
+      int answer = JvOptionPane.showConfirmDialog(this,
               MessageManager.formatMessage(
                       "label.fetch_references_for_3dbeacons",
                       seqsWithoutSourceDBRef.size()),
-
               MessageManager.getString("label.3dbeacons"),
-
-              JvOptionPane.YES_NO_OPTION,
-
-              JvOptionPane.PLAIN_MESSAGE,
-
-              null,
-
-              new Object[]
-              { MessageManager.getString("action.ok"),
-                  MessageManager.getString("action.cancel") },
-
-              MessageManager.getString("action.ok")
-
-      );
+              JvOptionPane.YES_NO_OPTION, JvOptionPane.PLAIN_MESSAGE);
       runThread = (answer == JvOptionPane.OK_OPTION);
     }
     if (runThread)