JAL-2326 updated references of JOptionPane to JvOptionPane
authortcofoegbu <tcnofoegbu@dundee.ac.uk>
Thu, 24 Nov 2016 16:18:54 +0000 (16:18 +0000)
committertcofoegbu <tcnofoegbu@dundee.ac.uk>
Thu, 24 Nov 2016 16:18:54 +0000 (16:18 +0000)
57 files changed:
examples/groovy/selectColumnsByFeatureAndGroup.groovy
src/MCview/PDBViewer.java
src/jalview/gui/AlignExportSettings.java
src/jalview/gui/AlignFrame.java
src/jalview/gui/AlignViewport.java
src/jalview/gui/AnnotationPanel.java
src/jalview/gui/AppJmol.java
src/jalview/gui/AppVarnaBinding.java
src/jalview/gui/AssociatePdbFileWithSeq.java
src/jalview/gui/ChimeraViewFrame.java
src/jalview/gui/CrossRefAction.java
src/jalview/gui/CutAndPasteTransfer.java
src/jalview/gui/DasSourceBrowser.java
src/jalview/gui/Desktop.java
src/jalview/gui/EPSOptions.java
src/jalview/gui/EditNameDialog.java
src/jalview/gui/FeatureRenderer.java
src/jalview/gui/FeatureSettings.java
src/jalview/gui/Finder.java
src/jalview/gui/FontChooser.java
src/jalview/gui/HTMLOptions.java
src/jalview/gui/IdPanel.java
src/jalview/gui/Jalview2XML.java
src/jalview/gui/Jalview2XML_V1.java
src/jalview/gui/JvOptionPane.java
src/jalview/gui/OOMWarning.java
src/jalview/gui/PCAPanel.java
src/jalview/gui/PopupMenu.java
src/jalview/gui/Preferences.java
src/jalview/gui/PromptUserConfig.java
src/jalview/gui/RestInputParamEditDialog.java
src/jalview/gui/SVGOptions.java
src/jalview/gui/SeqPanel.java
src/jalview/gui/SequenceFetcher.java
src/jalview/gui/StructureChooser.java
src/jalview/gui/StructureViewerBase.java
src/jalview/gui/TextColourChooser.java
src/jalview/gui/UserDefinedColours.java
src/jalview/gui/UserQuestionnaireCheck.java
src/jalview/gui/VamsasApplication.java
src/jalview/gui/WebserviceInfo.java
src/jalview/gui/WsJobParameters.java
src/jalview/gui/WsParamSetManager.java
src/jalview/gui/WsPreferences.java
src/jalview/io/FileLoader.java
src/jalview/io/JalviewFileChooser.java
src/jalview/io/WSWUBlastClient.java
src/jalview/jbgui/GAlignFrame.java
src/jalview/jbgui/GSequenceLink.java
src/jalview/ws/DasSequenceFeatureFetcher.java
src/jalview/ws/jws1/Discoverer.java
src/jalview/ws/jws1/JPredClient.java
src/jalview/ws/jws1/MsaWSClient.java
src/jalview/ws/jws1/SeqSearchWSClient.java
src/jalview/ws/jws2/MsaWSClient.java
src/jalview/ws/jws2/SequenceAnnotationWSClient.java
src/jalview/ws/rest/RestClient.java

index 0b479bf..b8edaa7 100644 (file)
@@ -92,8 +92,8 @@ return "Found a total of ${nfeat} features across ${nseq} sequences in ${nal} al
     
 String getFeatureInput(){
         def swingBuilder = new SwingBuilder();
-        def response = JOptionPane.showInputDialog(
-                   null, 'Select columns by feature by type','Enter type of feature', JOptionPane.OK_OPTION)
+        def response = JvOptionPane.showInputDialog(
+                   null, 'Select columns by feature by type','Enter type of feature', JvOptionPane.OK_OPTION)
 
         return response
     }
\ No newline at end of file
index eaa33df..d6b05c4 100755 (executable)
@@ -24,6 +24,7 @@ import jalview.datamodel.PDBEntry;
 import jalview.datamodel.SequenceI;
 import jalview.gui.AlignmentPanel;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.OOMWarning;
 import jalview.gui.UserDefinedColours;
 import jalview.io.JalviewFileChooser;
@@ -60,7 +61,6 @@ import javax.swing.JInternalFrame;
 import javax.swing.JMenu;
 import javax.swing.JMenuBar;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 import javax.swing.JRadioButtonMenuItem;
 
 public class PDBViewer extends JInternalFrame implements Runnable
@@ -436,13 +436,13 @@ public class PDBViewer extends JInternalFrame implements Runnable
           {
             radioItem.removeActionListener(radioItem.getActionListeners()[0]);
 
-            int option = JOptionPane.showInternalConfirmDialog(
+            int option = JvOptionPane.showInternalConfirmDialog(
                     jalview.gui.Desktop.desktop, MessageManager
                             .getString("label.remove_from_default_list"),
                     MessageManager
                             .getString("label.remove_user_defined_colour"),
-                    JOptionPane.YES_NO_OPTION);
-            if (option == JOptionPane.YES_OPTION)
+                    JvOptionPane.YES_NO_OPTION);
+            if (option == JvOptionPane.YES_OPTION)
             {
               jalview.gui.UserDefinedColours
                       .removeColourFromDefaults(radioItem.getText());
index 2a12630..a4fdd7d 100644 (file)
@@ -48,11 +48,12 @@ public class AlignExportSettings extends GAlignExportSettings implements
     {
 
       JOptionPane pane = new JOptionPane(null, JOptionPane.DEFAULT_OPTION,
-              JOptionPane.DEFAULT_OPTION, null, new Object[] { this });
+              JvOptionPane.DEFAULT_OPTION, null, new Object[] { this });
       dialog = pane.createDialog(Desktop.desktop,
               MessageManager.getString("label.export_settings"));
       dialog.addWindowListener(new WindowAdapter()
       {
+        @Override
         public void windowClosing(WindowEvent e)
         {
           cancelled = true;
@@ -66,6 +67,7 @@ public class AlignExportSettings extends GAlignExportSettings implements
     }
   }
 
+  @Override
   public void ok_actionPerformed(ActionEvent e)
   {
     cancelled = false;
@@ -73,6 +75,7 @@ public class AlignExportSettings extends GAlignExportSettings implements
     dialog.dispose();
   }
 
+  @Override
   public void cancel_actionPerformed(ActionEvent e)
   {
     cancelled = true;
@@ -110,6 +113,7 @@ public class AlignExportSettings extends GAlignExportSettings implements
     return chkExportGrps.isSelected();
   }
 
+  @Override
   public boolean isCancelled()
   {
     return cancelled;
index 6a637e3..7b751bf 100644 (file)
@@ -1128,14 +1128,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       currentFileFormat = chooser.getSelectedFormat();
       while (currentFileFormat == null)
       {
-        JOptionPane
+        JvOptionPane
                 .showInternalMessageDialog(
                         Desktop.desktop,
                         MessageManager
                                 .getString("label.select_file_format_before_saving"),
                         MessageManager
                                 .getString("label.file_format_not_specified"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
         currentFileFormat = chooser.getSelectedFormat();
         value = chooser.showSaveDialog(this);
         if (value != JalviewFileChooser.APPROVE_OPTION)
@@ -1236,11 +1236,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
 
     if (!success)
     {
-      JOptionPane.showInternalMessageDialog(this, MessageManager
+      JvOptionPane.showInternalMessageDialog(this, MessageManager
               .formatMessage("label.couldnt_save_file",
                       new Object[] { fileName }), MessageManager
               .getString("label.error_saving_file"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
     }
 
     return success;
@@ -1255,8 +1255,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     }
     else
     {
-      JOptionPane.showInternalMessageDialog(this, warning, title,
-              JOptionPane.WARNING_MESSAGE);
+      JvOptionPane.showInternalMessageDialog(this, warning, title,
+              JvOptionPane.WARNING_MESSAGE);
     }
     return;
   }
@@ -2368,13 +2368,13 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
               .getAlignment().getWidth()) ? true : false;
       if (isEntireAlignWidth)
       {
-        int confirm = JOptionPane.showConfirmDialog(this,
+        int confirm = JvOptionPane.showConfirmDialog(this,
                 MessageManager.getString("warn.delete_all"), // $NON-NLS-1$
                 MessageManager.getString("label.delete_all"), // $NON-NLS-1$
-                JOptionPane.OK_CANCEL_OPTION);
+                JvOptionPane.OK_CANCEL_OPTION);
 
-        if (confirm == JOptionPane.CANCEL_OPTION
-                || confirm == JOptionPane.CLOSED_OPTION)
+        if (confirm == JvOptionPane.CANCEL_OPTION
+                || confirm == JvOptionPane.CLOSED_OPTION)
         {
           return;
         }
@@ -3651,13 +3651,13 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
           {
             radioItem.removeActionListener(radioItem.getActionListeners()[0]);
 
-            int option = JOptionPane.showInternalConfirmDialog(
+            int option = JvOptionPane.showInternalConfirmDialog(
                     jalview.gui.Desktop.desktop, MessageManager
                             .getString("label.remove_from_default_list"),
                     MessageManager
                             .getString("label.remove_user_defined_colour"),
-                    JOptionPane.YES_NO_OPTION);
-            if (option == JOptionPane.YES_OPTION)
+                    JvOptionPane.YES_NO_OPTION);
+            if (option == JvOptionPane.YES_OPTION)
             {
               jalview.gui.UserDefinedColours
                       .removeColourFromDefaults(radioItem.getText());
@@ -3805,10 +3805,10 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     if ((viewport.getSelectionGroup() == null)
             || (viewport.getSelectionGroup().getSize() < 2))
     {
-      JOptionPane.showInternalMessageDialog(this, MessageManager
+      JvOptionPane.showInternalMessageDialog(this, MessageManager
               .getString("label.you_must_select_least_two_sequences"),
               MessageManager.getString("label.invalid_selection"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
     }
     else
     {
@@ -3834,14 +3834,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
             .getSelectionGroup().getSize() > 0))
             || (viewport.getAlignment().getHeight() < 4))
     {
-      JOptionPane
+      JvOptionPane
               .showInternalMessageDialog(
                       this,
                       MessageManager
                               .getString("label.principal_component_analysis_must_take_least_four_input_sequences"),
                       MessageManager
                               .getString("label.sequence_selection_insufficient"),
-                      JOptionPane.WARNING_MESSAGE);
+                      JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -3939,14 +3939,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     {
       if (viewport.getSelectionGroup().getSize() < 3)
       {
-        JOptionPane
+        JvOptionPane
                 .showMessageDialog(
                         Desktop.desktop,
                         MessageManager
                                 .getString("label.you_need_more_two_sequences_selected_build_tree"),
                         MessageManager
                                 .getString("label.not_enough_sequences"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
         return;
       }
 
@@ -3957,14 +3957,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       {
         if (_s.getLength() < sg.getEndRes())
         {
-          JOptionPane
+          JvOptionPane
                   .showMessageDialog(
                           Desktop.desktop,
                           MessageManager
                                   .getString("label.selected_region_to_tree_may_only_contain_residues_or_gaps"),
                           MessageManager
                                   .getString("label.sequences_selection_not_aligned"),
-                          JOptionPane.WARNING_MESSAGE);
+                          JvOptionPane.WARNING_MESSAGE);
 
           return;
         }
@@ -3978,14 +3978,14 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       // are the visible sequences aligned?
       if (!viewport.getAlignment().isAligned(false))
       {
-        JOptionPane
+        JvOptionPane
                 .showMessageDialog(
                         Desktop.desktop,
                         MessageManager
                                 .getString("label.sequences_must_be_aligned_before_creating_tree"),
                         MessageManager
                                 .getString("label.sequences_not_aligned"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
 
         return;
       }
@@ -4250,11 +4250,11 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     else if (viewport.getSelectionGroup() != null
             && viewport.getSelectionGroup().getSize() == 1)
     {
-      int option = JOptionPane.showConfirmDialog(this,
+      int option = JvOptionPane.showConfirmDialog(this,
               MessageManager.getString("warn.oneseq_msainput_selection"),
               MessageManager.getString("label.invalid_selection"),
-              JOptionPane.OK_CANCEL_OPTION);
-      if (option == JOptionPane.OK_OPTION)
+              JvOptionPane.OK_CANCEL_OPTION);
+      if (option == JvOptionPane.OK_OPTION)
       {
         msa = viewport.getAlignmentView(false);
       }
@@ -4330,21 +4330,21 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         viewport.setCurrentTree(ShowNewickTree(fin, choice).getTree());
       } catch (Exception ex)
       {
-        JOptionPane
+        JvOptionPane
                 .showMessageDialog(
                         Desktop.desktop,
                         ex.getMessage(),
                         MessageManager
                                 .getString("label.problem_reading_tree_file"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
         ex.printStackTrace();
       }
       if (fin != null && fin.hasWarningMessage())
       {
-        JOptionPane.showMessageDialog(Desktop.desktop, fin
+        JvOptionPane.showMessageDialog(Desktop.desktop, fin
                 .getWarningMessage(), MessageManager
                 .getString("label.possible_problem_with_tree_file"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
       }
     }
   }
@@ -4729,8 +4729,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       final String errorTitle = MessageManager
               .getString("label.implementation_error")
               + MessageManager.getString("label.translation_failed");
-      JOptionPane.showMessageDialog(Desktop.desktop, msg, errorTitle,
-              JOptionPane.ERROR_MESSAGE);
+      JvOptionPane.showMessageDialog(Desktop.desktop, msg, errorTitle,
+              JvOptionPane.ERROR_MESSAGE);
       return;
     }
     if (al == null || al.getHeight() == 0)
@@ -4739,8 +4739,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
               .getString("label.select_at_least_three_bases_in_at_least_one_sequence_to_cDNA_translation");
       final String errorTitle = MessageManager
               .getString("label.translation_failed");
-      JOptionPane.showMessageDialog(Desktop.desktop, msg, errorTitle,
-              JOptionPane.WARNING_MESSAGE);
+      JvOptionPane.showMessageDialog(Desktop.desktop, msg, errorTitle,
+              JvOptionPane.WARNING_MESSAGE);
     }
     else
     {
@@ -4911,7 +4911,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         if (filesmatched.size() > 0)
         {
           if (Cache.getDefault("AUTOASSOCIATE_PDBANDSEQS", false)
-                  || JOptionPane
+                  || JvOptionPane
                           .showConfirmDialog(
                                   this,
                                   MessageManager
@@ -4924,7 +4924,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                                                           .toString() }),
                                   MessageManager
                                           .getString("label.automatically_associate_structure_files_by_name"),
-                                  JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION)
+                                  JvOptionPane.YES_NO_OPTION) == JvOptionPane.YES_OPTION)
 
           {
             for (Object[] fm : filesmatched)
@@ -4954,7 +4954,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
         {
           if (assocfiles > 0
                   && (Cache.getDefault(
-                          "AUTOASSOCIATE_PDBANDSEQS_IGNOREOTHERS", false) || JOptionPane
+                          "AUTOASSOCIATE_PDBANDSEQS_IGNOREOTHERS", false) || JvOptionPane
                           .showConfirmDialog(
                                   this,
                                   "<html>"
@@ -4969,7 +4969,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                                           + "</html>",
                                   MessageManager
                                           .getString("label.ignore_unmatched_dropped_files"),
-                                  JOptionPane.YES_NO_OPTION) == JOptionPane.YES_OPTION))
+                                  JvOptionPane.YES_NO_OPTION) == JvOptionPane.YES_OPTION))
           {
             return;
           }
@@ -5034,7 +5034,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
             {
               // some problem - if no warning its probable that the ID matching
               // process didn't work
-              JOptionPane
+              JvOptionPane
                       .showMessageDialog(
                               Desktop.desktop,
                               tcf.getWarningMessage() == null ? MessageManager
@@ -5042,7 +5042,7 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
                                       : tcf.getWarningMessage(),
                               MessageManager
                                       .getString("label.problem_reading_tcoffee_score_file"),
-                              JOptionPane.WARNING_MESSAGE);
+                              JvOptionPane.WARNING_MESSAGE);
             }
           }
           else
@@ -5163,8 +5163,8 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
     if (e.isPopupTrigger())
     {
       String msg = MessageManager.getString("label.enter_view_name");
-      String reply = JOptionPane.showInternalInputDialog(this, msg, msg,
-              JOptionPane.QUESTION_MESSAGE);
+      String reply = JvOptionPane.showInternalInputDialog(this, msg, msg,
+              JvOptionPane.QUESTION_MESSAGE);
 
       if (reply != null)
       {
@@ -5903,12 +5903,12 @@ public class AlignFrame extends GAlignFrame implements DropTargetListener,
       } catch (Exception ex)
       {
         System.err.println((ex.toString()));
-        JOptionPane
+        JvOptionPane
                 .showInternalMessageDialog(Desktop.desktop, MessageManager
                         .getString("label.couldnt_run_groovy_script"),
                         MessageManager
                                 .getString("label.groovy_support_failed"),
-                        JOptionPane.ERROR_MESSAGE);
+                        JvOptionPane.ERROR_MESSAGE);
       }
     }
     else
index 03aee5d..39217e5 100644 (file)
@@ -876,9 +876,9 @@ public class AlignViewport extends AlignmentViewport implements
         MessageManager.getString("label.new_window"), };
     final String question = JvSwingUtils.wrapTooltip(true,
             MessageManager.getString("label.open_split_window?"));
-    int response = JOptionPane.showOptionDialog(Desktop.desktop, question,
+    int response = JvOptionPane.showOptionDialog(Desktop.desktop, question,
             MessageManager.getString("label.open_split_window"),
-            JOptionPane.DEFAULT_OPTION, JOptionPane.PLAIN_MESSAGE, null,
+            JvOptionPane.DEFAULT_OPTION, JvOptionPane.PLAIN_MESSAGE, null,
             options, options[0]);
 
     if (response != 1 && response != 2)
index 199c4e5..b1f0edb 100755 (executable)
@@ -300,7 +300,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
     else if (action.equals(LABEL))
     {
       String exMesg = collectAnnotVals(anot, LABEL);
-      String label = JOptionPane.showInputDialog(this,
+      String label = JvOptionPane.showInputDialog(this,
               MessageManager.getString("label.enter_label"), exMesg);
 
       if (label == null)
@@ -380,7 +380,7 @@ public class AnnotationPanel extends JPanel implements AwtRenderPanelI,
         aa[activeRow].hasIcons = true;
       }
 
-      String label = JOptionPane.showInputDialog(MessageManager
+      String label = JvOptionPane.showInputDialog(MessageManager
               .getString("label.enter_label_for_the_structure"), symbol);
 
       if (label == null)
index d7e8305..e2e54aa 100644 (file)
@@ -675,11 +675,11 @@ public class AppJmol extends StructureViewerBase
     }
     if (errormsgs.length() > 0)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.pdb_entries_couldnt_be_retrieved",
                       new String[] { errormsgs.toString() }),
               MessageManager.getString("label.couldnt_load_file"),
-              JOptionPane.ERROR_MESSAGE);
+              JvOptionPane.ERROR_MESSAGE);
     }
     return files;
   }
index 521bb3e..8ab1e61 100644 (file)
@@ -374,9 +374,9 @@ public class AppVarnaBinding extends JalviewVarnaBinding
 
       _sideList.ensureIndexIsVisible(index);
       /*
-       * TODO Object newName = JOptionPane.showInputDialog( this,
+       * TODO Object newName = JvOptionPane.showInputDialog( this,
        * "Specify a new name for this RNA", "Rename RNA",
-       * JOptionPane.QUESTION_MESSAGE, (Icon)null, null, item.toString()); if
+       * JvOptionPane.QUESTION_MESSAGE, (Icon)null, null, item.toString()); if
        * (newName!=null) { item.name = newName.toString();
        * this._sideList.repaint(); }
        */
index e2637a9..f0cee7c 100644 (file)
@@ -64,11 +64,11 @@ public class AssociatePdbFileWithSeq
 
       if (prompt)
       {
-        reply = JOptionPane.showInternalInputDialog(Desktop.desktop,
+        reply = JvOptionPane.showInternalInputDialog(Desktop.desktop,
                 MessageManager
                         .getString("label.couldnt_find_pdb_id_in_file"),
                 MessageManager.getString("label.no_pdb_id_in_file"),
-                JOptionPane.QUESTION_MESSAGE);
+                JvOptionPane.QUESTION_MESSAGE);
       }
       if (reply == null)
       {
index fe12f40..90ad51d 100644 (file)
@@ -377,10 +377,10 @@ public class ChimeraViewFrame extends StructureViewerBase
 
     if (!jmb.launchChimera())
     {
-      JOptionPane.showMessageDialog(Desktop.desktop,
+      JvOptionPane.showMessageDialog(Desktop.desktop,
               MessageManager.getString("label.chimera_failed"),
               MessageManager.getString("label.error_loading_file"),
-              JOptionPane.ERROR_MESSAGE);
+              JvOptionPane.ERROR_MESSAGE);
       this.dispose();
       return;
     }
@@ -441,18 +441,18 @@ public class ChimeraViewFrame extends StructureViewerBase
                 "label.confirm_close_chimera",
                 new Object[] { jmb.getViewerTitle("Chimera", false) });
         prompt = JvSwingUtils.wrapTooltip(true, prompt);
-        int confirm = JOptionPane.showConfirmDialog(this, prompt,
+        int confirm = JvOptionPane.showConfirmDialog(this, prompt,
                 MessageManager.getString("label.close_viewer"),
-                JOptionPane.YES_NO_CANCEL_OPTION);
+                JvOptionPane.YES_NO_CANCEL_OPTION);
         /*
          * abort closure if user hits escape or Cancel
          */
-        if (confirm == JOptionPane.CANCEL_OPTION
-                || confirm == JOptionPane.CLOSED_OPTION)
+        if (confirm == JvOptionPane.CANCEL_OPTION
+                || confirm == JvOptionPane.CLOSED_OPTION)
         {
           return;
         }
-        closeChimera = confirm == JOptionPane.YES_OPTION;
+        closeChimera = confirm == JvOptionPane.YES_OPTION;
       }
       jmb.closeViewer(closeChimera);
     }
@@ -541,11 +541,11 @@ public class ChimeraViewFrame extends StructureViewerBase
     if (errormsgs.length() > 0)
     {
 
-      JOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.pdb_entries_couldnt_be_retrieved",
                       new Object[] { errormsgs.toString() }),
               MessageManager.getString("label.couldnt_load_file"),
-              JOptionPane.ERROR_MESSAGE);
+              JvOptionPane.ERROR_MESSAGE);
     }
 
     if (files.length() > 0)
index 32af226..7768b22 100644 (file)
@@ -121,10 +121,10 @@ public class CrossRefAction implements Runnable
                   xrefsAlignment.getSequencesArray());
           if (copyAlignment.getHeight() == 0)
           {
-            JOptionPane.showMessageDialog(alignFrame,
+            JvOptionPane.showMessageDialog(alignFrame,
                     MessageManager.getString("label.cant_map_cds"),
                     MessageManager.getString("label.operation_failed"),
-                    JOptionPane.OK_OPTION);
+                    JvOptionPane.OK_OPTION);
             System.err.println("Failed to make CDS alignment");
           }
 
index ed2b9bf..4184eca 100644 (file)
@@ -51,7 +51,6 @@ import java.awt.event.ActionListener;
 import java.awt.event.MouseEvent;
 
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 import javax.swing.JPopupMenu;
 import javax.swing.SwingUtilities;
 
@@ -220,10 +219,10 @@ public class CutAndPasteTransfer extends GCutAndPasteTransfer
               .getString("label.couldnt_read_data"));
       if (!Jalview.isHeadlessMode())
       {
-        javax.swing.JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 AppletFormatAdapter.SUPPORTED_FORMATS,
                 MessageManager.getString("label.couldnt_read_data"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
       }
       return;
     }
@@ -241,12 +240,12 @@ public class CutAndPasteTransfer extends GCutAndPasteTransfer
 
       } catch (java.io.IOException ex)
       {
-        JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 MessageManager.formatMessage(
                         "label.couldnt_read_pasted_text",
                         new String[] { ex.toString() }), MessageManager
                         .getString("label.error_parsing_text"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
       }
     }
 
@@ -330,10 +329,10 @@ public class CutAndPasteTransfer extends GCutAndPasteTransfer
               .getString("label.couldnt_read_data"));
       if (!Jalview.isHeadlessMode())
       {
-        javax.swing.JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 AppletFormatAdapter.SUPPORTED_FORMATS,
                 MessageManager.getString("label.couldnt_read_data"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
       }
     }
   }
index e677084..8c8f228 100644 (file)
@@ -459,12 +459,12 @@ public class DasSourceBrowser extends GDasSourceBrowser implements
     pane12.add(urltf, BorderLayout.EAST);
     panel.add(pane12, BorderLayout.SOUTH);
 
-    int reply = JOptionPane.showInternalConfirmDialog(Desktop.desktop,
+    int reply = JvOptionPane.showInternalConfirmDialog(Desktop.desktop,
             panel,
             MessageManager.getString("label.enter_local_das_source"),
-            JOptionPane.OK_CANCEL_OPTION);
+            JvOptionPane.OK_CANCEL_OPTION);
 
-    if (reply != JOptionPane.OK_OPTION)
+    if (reply != JvOptionPane.OK_OPTION)
     {
       return;
     }
@@ -534,21 +534,21 @@ public class DasSourceBrowser extends GDasSourceBrowser implements
 
     if (!sourceRegistry.getSource(nickname).isLocal())
     {
-      JOptionPane
+      JvOptionPane
               .showInternalMessageDialog(
                       Desktop.desktop,
                       MessageManager
                               .getString("label.you_can_only_edit_or_remove_local_das_sources"),
                       MessageManager.getString("label.public_das_source"),
-                      JOptionPane.WARNING_MESSAGE);
+                      JvOptionPane.WARNING_MESSAGE);
       return;
     }
 
     Object[] options = { "Edit", "Remove", "Cancel" };
-    int choice = JOptionPane.showInternalOptionDialog(Desktop.desktop,
+    int choice = JvOptionPane.showInternalOptionDialog(Desktop.desktop,
             "Do you want to edit or remove " + nickname + "?",
             "Edit / Remove Local DAS Source",
-            JOptionPane.YES_NO_CANCEL_OPTION, JOptionPane.QUESTION_MESSAGE,
+            JvOptionPane.YES_NO_CANCEL_OPTION, JvOptionPane.QUESTION_MESSAGE,
             null, options, options[2]);
 
     switch (choice)
index 28606f1..6dd7557 100644 (file)
@@ -1086,11 +1086,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
       }
     }
 
-    int reply = JOptionPane.showInternalConfirmDialog(desktop, panel,
+    int reply = JvOptionPane.showInternalConfirmDialog(desktop, panel,
             MessageManager.getString("label.input_alignment_from_url"),
-            JOptionPane.OK_CANCEL_OPTION);
+            JvOptionPane.OK_CANCEL_OPTION);
 
-    if (reply != JOptionPane.OK_OPTION)
+    if (reply != JvOptionPane.OK_OPTION)
     {
       return;
     }
@@ -1115,11 +1115,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
 
       if (format.equals("URL NOT FOUND"))
       {
-        JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 MessageManager.formatMessage("label.couldnt_locate",
                         new Object[] { url }), MessageManager
                         .getString("label.url_not_found"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
 
         return;
       }
@@ -1214,9 +1214,9 @@ public class Desktop extends jalview.jbgui.GDesktop implements
   public void aboutMenuItem_actionPerformed(ActionEvent e)
   {
     // StringBuffer message = getAboutMessage(false);
-    // JOptionPane.showInternalMessageDialog(Desktop.desktop,
+    // JvOptionPane.showInternalMessageDialog(Desktop.desktop,
     //
-    // message.toString(), "About Jalview", JOptionPane.INFORMATION_MESSAGE);
+    // message.toString(), "About Jalview", JvOptionPane.INFORMATION_MESSAGE);
     new Thread(new Runnable()
     {
       @Override
@@ -1556,11 +1556,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
             Cache.log.error(
                     "Problems whilst trying to save to " + choice.getName(),
                     ex);
-            JOptionPane.showMessageDialog(me, MessageManager.formatMessage(
+            JvOptionPane.showMessageDialog(me, MessageManager.formatMessage(
                     "label.error_whilst_saving_current_state_to",
                     new Object[] { choice.getName() }), MessageManager
                     .getString("label.couldnt_save_project"),
-                    JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
           setProgressBar(null, choice.hashCode());
         }
@@ -1622,12 +1622,12 @@ public class Desktop extends jalview.jbgui.GDesktop implements
           {
             Cache.log.error("Problems whilst loading project from "
                     + choice, ex);
-            JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+            JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
                     .formatMessage(
                             "label.error_whilst_loading_project_from",
                             new Object[] { choice }), MessageManager
                     .getString("label.couldnt_load_project"),
-                    JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
           setProgressBar(null, choice.hashCode());
         }
@@ -1912,7 +1912,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
         String fle = chooser.getSelectedFile().toString();
         if (!vamsasImport(chooser.getSelectedFile()))
         {
-          JOptionPane
+          JvOptionPane
                   .showInternalMessageDialog(
                           Desktop.desktop,
                           MessageManager.formatMessage(
@@ -1920,7 +1920,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
                                   new Object[] { fle }),
                           MessageManager
                                   .getString("label.vamsas_document_import_failed"),
-                          JOptionPane.ERROR_MESSAGE);
+                          JvOptionPane.ERROR_MESSAGE);
         }
       }
     }
@@ -2212,9 +2212,9 @@ public class Desktop extends jalview.jbgui.GDesktop implements
         removeProgressPanel(progpanel);
         if (warnmsg != null)
         {
-          JOptionPane.showInternalMessageDialog(Desktop.desktop,
+          JvOptionPane.showInternalMessageDialog(Desktop.desktop,
 
-          warnmsg, warnttl, JOptionPane.ERROR_MESSAGE);
+          warnmsg, warnttl, JvOptionPane.ERROR_MESSAGE);
         }
       }
     }
@@ -2334,10 +2334,10 @@ public class Desktop extends jalview.jbgui.GDesktop implements
           });
           msgPanel.add(jcb);
 
-          JOptionPane.showMessageDialog(Desktop.desktop, msgPanel,
+          JvOptionPane.showMessageDialog(Desktop.desktop, msgPanel,
                   MessageManager
                           .getString("label.SEQUENCE_ID_no_longer_used"),
-                  JOptionPane.WARNING_MESSAGE);
+                  JvOptionPane.WARNING_MESSAGE);
         }
       }
     });
@@ -2544,11 +2544,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
     } catch (Exception ex)
     {
       jalview.bin.Cache.log.error("Groovy Shell Creation failed.", ex);
-      JOptionPane.showInternalMessageDialog(Desktop.desktop,
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop,
 
       MessageManager.getString("label.couldnt_create_groovy_shell"),
               MessageManager.getString("label.groovy_support_failed"),
-              JOptionPane.ERROR_MESSAGE);
+              JvOptionPane.ERROR_MESSAGE);
     }
   }
 
@@ -2889,7 +2889,7 @@ public class Desktop extends jalview.jbgui.GDesktop implements
                  * 
                  * jd.waitForInput();
                  */
-                JOptionPane
+                JvOptionPane
                         .showConfirmDialog(
                                 Desktop.desktop,
                                 new JLabel(
@@ -2901,8 +2901,8 @@ public class Desktop extends jalview.jbgui.GDesktop implements
                                                 + "<p>Check the <em>Connections</em> and <em>Web services</em> tab<br/>of the"
                                                 + " Tools->Preferences dialog box to change them.</p></html>"),
                                 "Web Service Configuration Problem",
-                                JOptionPane.DEFAULT_OPTION,
-                                JOptionPane.ERROR_MESSAGE);
+                                JvOptionPane.DEFAULT_OPTION,
+                                JvOptionPane.ERROR_MESSAGE);
                 serviceChangedDialog = null;
 
               }
@@ -2959,11 +2959,11 @@ public class Desktop extends jalview.jbgui.GDesktop implements
           jalview.util.BrowserLauncher.openURL(url);
         } catch (Exception ex)
         {
-          JOptionPane.showInternalMessageDialog(Desktop.desktop,
+          JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                   MessageManager
                           .getString("label.web_browser_not_found_unix"),
                   MessageManager.getString("label.web_browser_not_found"),
-                  JOptionPane.WARNING_MESSAGE);
+                  JvOptionPane.WARNING_MESSAGE);
 
           ex.printStackTrace();
         }
index 69fde89..fa67999 100644 (file)
@@ -58,8 +58,8 @@ public class EPSOptions extends JPanel
     bg.add(lineart);
     bg.add(text);
 
-    JOptionPane pane = new JOptionPane(null, JOptionPane.DEFAULT_OPTION,
-            JOptionPane.DEFAULT_OPTION, null, new Object[] { this });
+    JOptionPane pane = new JOptionPane(null, JvOptionPane.DEFAULT_OPTION,
+            JvOptionPane.DEFAULT_OPTION, null, new Object[] { this });
 
     dialog = pane.createDialog(Desktop.desktop, "EPS Rendering options");
     dialog.setVisible(true);
@@ -78,6 +78,7 @@ public class EPSOptions extends JPanel
     ok.setText(MessageManager.getString("action.ok"));
     ok.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         ok_actionPerformed(e);
@@ -86,6 +87,7 @@ public class EPSOptions extends JPanel
     cancel.setText(MessageManager.getString("action.cancel"));
     cancel.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         cancel_actionPerformed(e);
index baad794..0ec4a87 100644 (file)
@@ -80,13 +80,13 @@ public class EditNameDialog
       panel2.add(description, BorderLayout.CENTER);
       panel.add(panel2, BorderLayout.SOUTH);
     }
-    int reply = JOptionPane.showInternalConfirmDialog(parent, panel, title,
-            JOptionPane.OK_CANCEL_OPTION);
+    int reply = JvOptionPane.showInternalConfirmDialog(parent, panel, title,
+            JvOptionPane.OK_CANCEL_OPTION);
     if (!parent.requestFocusInWindow())
     {
       System.err.println("Bad focus for dialog!");
     }
-    if (reply == JOptionPane.OK_OPTION)
+    if (reply == JvOptionPane.OK_OPTION)
     {
       accept = true;
     }
index 83d1612..ae911ed 100644 (file)
@@ -330,14 +330,14 @@ public class FeatureRenderer extends
             : MessageManager.formatMessage("label.amend_delete_features",
                     new String[] { sequences[0].getName() });
 
-    int reply = JOptionPane.showInternalOptionDialog(Desktop.desktop,
-            bigPanel, title, JOptionPane.YES_NO_CANCEL_OPTION,
-            JOptionPane.QUESTION_MESSAGE, null, options,
+    int reply = JvOptionPane.showInternalOptionDialog(Desktop.desktop,
+            bigPanel, title, JvOptionPane.YES_NO_CANCEL_OPTION,
+            JvOptionPane.QUESTION_MESSAGE, null, options,
             MessageManager.getString("action.ok"));
 
     jalview.io.FeaturesFile ffile = new jalview.io.FeaturesFile();
 
-    if (reply == JOptionPane.OK_OPTION && name.getText().length() > 0)
+    if (reply == JvOptionPane.OK_OPTION && name.getText().length() > 0)
     {
       // This ensures that the last sequence
       // is refreshed and new features are rendered
@@ -356,11 +356,11 @@ public class FeatureRenderer extends
     {
       SequenceFeature sf = features[featureIndex];
 
-      if (reply == JOptionPane.NO_OPTION)
+      if (reply == JvOptionPane.NO_OPTION)
       {
         sequences[0].getDatasetSequence().deleteFeature(sf);
       }
-      else if (reply == JOptionPane.YES_OPTION)
+      else if (reply == JvOptionPane.YES_OPTION)
       {
         sf.type = lastFeatureAdded;
         sf.featureGroup = lastFeatureGroupAdded;
@@ -383,7 +383,7 @@ public class FeatureRenderer extends
     else
     // NEW FEATURES ADDED
     {
-      if (reply == JOptionPane.OK_OPTION && lastFeatureAdded.length() > 0)
+      if (reply == JvOptionPane.OK_OPTION && lastFeatureAdded.length() > 0)
       {
         for (int i = 0; i < sequences.length; i++)
         {
index 15f3e5b..e3cdf76 100644 (file)
@@ -1402,15 +1402,15 @@ public class FeatureSettings extends JPanel implements
   public void noDasSourceActive()
   {
     complete();
-    JOptionPane
+    JvOptionPane
             .showInternalConfirmDialog(
                     Desktop.desktop,
                     MessageManager
                             .getString("label.no_das_sources_selected_warn"),
                     MessageManager
                             .getString("label.no_das_sources_selected_title"),
-                    JOptionPane.DEFAULT_OPTION,
-                    JOptionPane.INFORMATION_MESSAGE);
+                    JvOptionPane.DEFAULT_OPTION,
+                    JvOptionPane.INFORMATION_MESSAGE);
   }
 
   // ///////////////////////////////////////////////////////////////////////
index a8dbc38..af23ceb 100755 (executable)
@@ -293,9 +293,9 @@ public class Finder extends GFinder
     // 'SelectRegion' selection
     if (!haveResults)
     {
-      JOptionPane.showInternalMessageDialog(this,
+      JvOptionPane.showInternalMessageDialog(this,
               MessageManager.getString("label.finished_searching"), null,
-              JOptionPane.INFORMATION_MESSAGE);
+              JvOptionPane.INFORMATION_MESSAGE);
       resIndex = -1;
       seqIndex = 0;
     }
@@ -315,8 +315,8 @@ public class Finder extends GFinder
           message += searchResults.getSize()
                   + " subsequence matches found.";
         }
-        JOptionPane.showInternalMessageDialog(this, message, null,
-                JOptionPane.INFORMATION_MESSAGE);
+        JvOptionPane.showInternalMessageDialog(this, message, null,
+                JvOptionPane.INFORMATION_MESSAGE);
         resIndex = -1;
         seqIndex = 0;
       }
@@ -338,9 +338,9 @@ public class Finder extends GFinder
     {
       return false;
     }
-    JOptionPane.showInternalMessageDialog(this, error,
+    JvOptionPane.showInternalMessageDialog(this, error,
             MessageManager.getString("label.invalid_search"), // $NON-NLS-1$
-            JOptionPane.ERROR_MESSAGE);
+            JvOptionPane.ERROR_MESSAGE);
     return true;
   }
 
index 1f6c068..8220aea 100755 (executable)
@@ -253,9 +253,9 @@ public class FontChooser extends GFontChooser
       String message = iBounds.getHeight() < 1 ? MessageManager
               .getString("label.font_doesnt_have_letters_defined")
               : MessageManager.getString("label.font_too_small");
-      JOptionPane.showInternalMessageDialog(this, message,
+      JvOptionPane.showInternalMessageDialog(this, message,
               MessageManager.getString("label.invalid_font"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       /*
        * Restore the changed value - note this will reinvoke this method via the
        * ActionListener, but now validation should pass
index 108080b..12af734 100644 (file)
@@ -58,8 +58,8 @@ public class HTMLOptions extends JPanel
     bg.add(lineart);
     bg.add(text);
 
-    JOptionPane pane = new JOptionPane(null, JOptionPane.DEFAULT_OPTION,
-            JOptionPane.DEFAULT_OPTION, null, new Object[] { this });
+    JOptionPane pane = new JOptionPane(null, JvOptionPane.DEFAULT_OPTION,
+            JvOptionPane.DEFAULT_OPTION, null, new Object[] { this });
 
     dialog = pane.createDialog(Desktop.desktop, "HTML Rendering options");
     dialog.setVisible(true);
@@ -78,6 +78,7 @@ public class HTMLOptions extends JPanel
     ok.setText(MessageManager.getString("action.ok"));
     ok.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         ok_actionPerformed(e);
@@ -86,6 +87,7 @@ public class HTMLOptions extends JPanel
     cancel.setText(MessageManager.getString("action.cancel"));
     cancel.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         cancel_actionPerformed(e);
index 6a20872..59d12d9 100755 (executable)
@@ -254,10 +254,10 @@ public class IdPanel extends JPanel implements MouseListener,
       jalview.util.BrowserLauncher.openURL(url);
     } catch (Exception ex)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop,
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop,
               MessageManager.getString("label.web_browser_not_found_unix"),
               MessageManager.getString("label.web_browser_not_found"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       ex.printStackTrace();
     }
   }
index bc5e1d8..00c32e9 100644 (file)
@@ -2636,10 +2636,10 @@ public class Jalview2XML
           @Override
           public void run()
           {
-            JOptionPane.showInternalMessageDialog(Desktop.desktop,
+            JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                     finalErrorMessage, "Error "
                             + (saving ? "saving" : "loading")
-                            + " Jalview file", JOptionPane.WARNING_MESSAGE);
+                            + " Jalview file", JvOptionPane.WARNING_MESSAGE);
           }
         });
       }
index 3b39be7..2e6706c 100755 (executable)
@@ -155,11 +155,11 @@ public class Jalview2XML_V1
 
             System.err.println("Couldn't locate Jalview XML file : " + ex
                     + "\n");
-            JOptionPane.showInternalMessageDialog(Desktop.desktop,
+            JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                     MessageManager.formatMessage("label.couldnt_locate",
                             new String[] { file }), MessageManager
                             .getString("label.url_not_found"),
-                    JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
         });
       }
@@ -176,12 +176,12 @@ public class Jalview2XML_V1
           public void run()
           {
 
-            JOptionPane.showInternalMessageDialog(Desktop.desktop,
+            JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                     MessageManager.formatMessage(
                             "label.error_loading_file_params", new String[]
                             { file }), MessageManager
                             .getString("label.error_loading_jalview_file"),
-                    JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
         });
       }
index a6192be..539f3c2 100644 (file)
@@ -272,16 +272,6 @@ public class JvOptionPane extends JOptionPane
             .toString();
   }
 
-  // (mockResponse != DONT_MOCK) ? mockResponse :
-  // if (isMockMode())
-  // {
-  //
-  // }
-  // else
-  // {
-  // JOptionPane
-  // }
-
   private static void outputMessage(Object message)
   {
     System.out.println(">>> JOption Message : " + message.toString());
index eb4425e..f519b85 100644 (file)
@@ -75,13 +75,15 @@ public class OOMWarning implements Runnable
     this(string, oomerror, Desktop.desktop);
   }
 
+  @Override
   public void run()
   {
-    javax.swing.JOptionPane.showInternalMessageDialog(desktop,
+    JvOptionPane
+            .showInternalMessageDialog(desktop,
             MessageManager.formatMessage("warn.out_of_memory_when_action",
                     new String[] { action }), MessageManager
                     .getString("label.out_of_memory"),
-            javax.swing.JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
     // hope that there's enough memory left that no more appear.
     oomInprogress = false;
   }
index 51d247d..4f5a018 100644 (file)
@@ -114,10 +114,10 @@ public class PCAPanel extends GPCAPanel implements Runnable,
 
     if (!sameLength)
     {
-      JOptionPane.showMessageDialog(Desktop.desktop,
+      JvOptionPane.showMessageDialog(Desktop.desktop,
               MessageManager.getString("label.pca_sequences_not_aligned"),
               MessageManager.getString("label.sequences_not_aligned"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
index 5825382..cf010dc 100644 (file)
@@ -2088,14 +2088,14 @@ public class PopupMenu extends JPopupMenu
     {
       if (dialog.getName().indexOf(" ") > -1)
       {
-        JOptionPane
+        JvOptionPane
                 .showMessageDialog(
                         ap,
                         MessageManager
                                 .getString("label.spaces_converted_to_backslashes"),
                         MessageManager
                                 .getString("label.no_spaces_allowed_sequence_name"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
       }
 
       sequence.setName(dialog.getName().replace(' ', '_'));
@@ -2194,10 +2194,10 @@ public class PopupMenu extends JPopupMenu
       jalview.util.BrowserLauncher.openURL(url);
     } catch (Exception ex)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop,
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop,
               MessageManager.getString("label.web_browser_not_found_unix"),
               MessageManager.getString("label.web_browser_not_found"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       ex.printStackTrace();
     }
index 3bffd3a..b293e6f 100755 (executable)
@@ -754,9 +754,9 @@ public class Preferences extends GPreferences
     boolean valid = false;
     while (!valid)
     {
-      if (JOptionPane.showInternalConfirmDialog(Desktop.desktop, link,
+      if (JvOptionPane.showInternalConfirmDialog(Desktop.desktop, link,
               MessageManager.getString("label.new_sequence_url_link"),
-              JOptionPane.OK_CANCEL_OPTION, -1, null) == JOptionPane.OK_OPTION)
+              JvOptionPane.OK_CANCEL_OPTION, -1, null) == JvOptionPane.OK_OPTION)
       {
         if (link.checkValid())
         {
@@ -781,10 +781,10 @@ public class Preferences extends GPreferences
     int index = linkNameList.getSelectedIndex();
     if (index == -1)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop,
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop,
               MessageManager.getString("label.no_link_selected"),
               MessageManager.getString("label.no_link_selected"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       return;
     }
 
@@ -795,9 +795,9 @@ public class Preferences extends GPreferences
     while (!valid)
     {
 
-      if (JOptionPane.showInternalConfirmDialog(Desktop.desktop, link,
+      if (JvOptionPane.showInternalConfirmDialog(Desktop.desktop, link,
               MessageManager.getString("label.new_sequence_url_link"),
-              JOptionPane.OK_CANCEL_OPTION, -1, null) == JOptionPane.OK_OPTION)
+              JvOptionPane.OK_CANCEL_OPTION, -1, null) == JvOptionPane.OK_OPTION)
       {
         if (link.checkValid())
         {
@@ -821,10 +821,10 @@ public class Preferences extends GPreferences
     int index = linkNameList.getSelectedIndex();
     if (index == -1)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop,
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop,
               MessageManager.getString("label.no_link_selected"),
               MessageManager.getString("label.no_link_selected"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       return;
     }
     nameLinks.removeElementAt(index);
@@ -916,10 +916,10 @@ public class Preferences extends GPreferences
       }
     } catch (NumberFormatException x)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
               .getString("warn.user_defined_width_requirements"),
               MessageManager.getString("label.invalid_id_column_width"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       userIdWidth.setText("");
     }
   }
@@ -942,10 +942,10 @@ public class Preferences extends GPreferences
       File f = new File(chimeraPath.getText());
       if (!f.canExecute())
       {
-        JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 MessageManager.getString("label.invalid_chimera_path"),
                 MessageManager.getString("label.invalid_name"),
-                JOptionPane.ERROR_MESSAGE);
+                JvOptionPane.ERROR_MESSAGE);
         return false;
       }
     }
@@ -981,13 +981,13 @@ public class Preferences extends GPreferences
     if (!found)
     {
       String[] options = { "OK", "Help" };
-      int showHelp = JOptionPane.showInternalOptionDialog(
+      int showHelp = JvOptionPane.showInternalOptionDialog(
               Desktop.desktop,
               JvSwingUtils.wrapTooltip(true,
                       MessageManager.getString("label.chimera_missing")),
-              "", JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE,
+              "", JvOptionPane.YES_NO_OPTION, JvOptionPane.WARNING_MESSAGE,
               null, options, options[0]);
-      if (showHelp == JOptionPane.NO_OPTION)
+      if (showHelp == JvOptionPane.NO_OPTION)
       {
         try
         {
index d7449d0..fb90ce7 100644 (file)
@@ -201,12 +201,12 @@ public class PromptUserConfig implements Runnable
     }
     try
     {
-      int reply = JOptionPane.showConfirmDialog(
+      int reply = JvOptionPane.showConfirmDialog(
               Desktop.desktop, // component,
               dialogText, dialogTitle,
-              (allowCancel) ? JOptionPane.YES_NO_CANCEL_OPTION
-                      : JOptionPane.YES_NO_OPTION,
-              JOptionPane.QUESTION_MESSAGE);
+              (allowCancel) ? JvOptionPane.YES_NO_CANCEL_OPTION
+                      : JvOptionPane.YES_NO_OPTION,
+              JvOptionPane.QUESTION_MESSAGE);
       // now, ask the desktop to relayer any external windows that might have
       // been obsured
       if (Desktop.instance != null)
@@ -215,11 +215,11 @@ public class PromptUserConfig implements Runnable
       }
       // and finish parsing the result
       jalview.bin.Cache.log.debug("Got response : " + reply);
-      if (reply == JOptionPane.YES_OPTION)
+      if (reply == JvOptionPane.YES_OPTION)
       {
         jalview.bin.Cache.setProperty(property, "true");
       }
-      else if (reply == JOptionPane.NO_OPTION)
+      else if (reply == JvOptionPane.NO_OPTION)
       {
         if (removeifunset)
         {
index 8056189..19a9b51 100644 (file)
@@ -74,13 +74,13 @@ public class RestInputParamEditDialog extends GRestInputParamEditDialog
     @Override
     protected void okPressed()
     {
-      reply = JOptionPane.OK_OPTION;
+      reply = JvOptionPane.OK_OPTION;
     }
 
     @Override
     protected void cancelPressed()
     {
-      reply = JOptionPane.CANCEL_OPTION;
+      reply = JvOptionPane.CANCEL_OPTION;
 
     }
   };
@@ -107,14 +107,14 @@ public class RestInputParamEditDialog extends GRestInputParamEditDialog
             + currentservice.getName(), 600, 800);
 
     initTypeLists();
-    reply = JOptionPane.CANCEL_OPTION;
+    reply = JvOptionPane.CANCEL_OPTION;
     old = toedit;
     current = null;
     if (old != null)
     {
       setStateFor(old);
     }
-    updated = updated && reply == JOptionPane.OK_OPTION;
+    updated = updated && reply == JvOptionPane.OK_OPTION;
     frame.validate();
   }
 
index a64819a..ea8e360 100644 (file)
@@ -58,8 +58,8 @@ public class SVGOptions extends JPanel
     bg.add(lineart);
     bg.add(text);
 
-    JOptionPane pane = new JOptionPane(null, JOptionPane.DEFAULT_OPTION,
-            JOptionPane.DEFAULT_OPTION, null, new Object[] { this });
+    JOptionPane pane = new JOptionPane(null, JvOptionPane.DEFAULT_OPTION,
+            JvOptionPane.DEFAULT_OPTION, null, new Object[] { this });
 
     dialog = pane.createDialog(Desktop.desktop, "SVG Rendering options");
     dialog.setVisible(true);
@@ -78,6 +78,7 @@ public class SVGOptions extends JPanel
     ok.setText(MessageManager.getString("action.ok"));
     ok.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         ok_actionPerformed(e);
@@ -86,6 +87,7 @@ public class SVGOptions extends JPanel
     cancel.setText(MessageManager.getString("action.cancel"));
     cancel.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         cancel_actionPerformed(e);
index 36fb052..8726c4a 100644 (file)
@@ -1566,10 +1566,10 @@ public class SeqPanel extends JPanel implements MouseListener,
 
     if (av.getWrapAlignment() && seq > av.getAlignment().getHeight())
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
               .getString("label.cannot_edit_annotations_in_wrapped_view"),
               MessageManager.getString("label.wrapped_view_no_edit"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       return;
     }
 
index bbe2f68..d5fa86d 100755 (executable)
@@ -234,14 +234,14 @@ public class SequenceFetcher extends JPanel implements Runnable
             @Override
             public void run()
             {
-              JOptionPane
+              JvOptionPane
                       .showInternalMessageDialog(
                               Desktop.desktop,
                               MessageManager
                                       .getString("warn.couldnt_create_sequence_fetcher_client"),
                               MessageManager
                                       .getString("label.couldnt_create_sequence_fetcher"),
-                              JOptionPane.ERROR_MESSAGE);
+                              JvOptionPane.ERROR_MESSAGE);
             }
           });
 
@@ -1059,9 +1059,9 @@ public class SequenceFetcher extends JPanel implements Runnable
       @Override
       public void run()
       {
-        JOptionPane.showInternalMessageDialog(Desktop.desktop, error,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop, error,
                 MessageManager.getString("label.error_retrieving_data"),
-                JOptionPane.WARNING_MESSAGE);
+                JvOptionPane.WARNING_MESSAGE);
       }
     });
   }
index 21b6e4f..0c3aa2a 100644 (file)
@@ -216,9 +216,9 @@ public class StructureChooser extends GStructureChooser implements
         {
           errorMsg.append(error).append("\n");
         }
-        JOptionPane.showMessageDialog(this, errorMsg.toString(),
+        JvOptionPane.showMessageDialog(this, errorMsg.toString(),
                 MessageManager.getString("label.pdb_web-service_error"),
-                JOptionPane.ERROR_MESSAGE);
+                JvOptionPane.ERROR_MESSAGE);
       }
     }
   }
@@ -484,11 +484,11 @@ public class StructureChooser extends GStructureChooser implements
             {
               errorMsg.append(error).append("\n");
             }
-            JOptionPane.showMessageDialog(
+            JvOptionPane.showMessageDialog(
                     null,
                     errorMsg.toString(),
                     MessageManager.getString("label.pdb_web-service_error"),
-                    JOptionPane.ERROR_MESSAGE);
+                    JvOptionPane.ERROR_MESSAGE);
           }
         }
 
index 4715e48..a23b45f 100644 (file)
@@ -336,17 +336,17 @@ public abstract class StructureViewerBase extends GStructureViewer
    * 
    * @param pdbId
    * @param view
-   * @return YES, NO or CANCEL JOptionPane code
+   * @return YES, NO or CANCEL JvOptionPane code
    */
   protected int chooseAlignStructureToViewer(String pdbId,
           StructureViewerBase view)
   {
-    int option = JOptionPane.showInternalConfirmDialog(Desktop.desktop,
+    int option = JvOptionPane.showInternalConfirmDialog(Desktop.desktop,
             MessageManager.formatMessage("label.add_pdbentry_to_view",
                     new Object[] { pdbId, view.getTitle() }),
             MessageManager
                     .getString("label.align_to_existing_structure_view"),
-            JOptionPane.YES_NO_CANCEL_OPTION);
+            JvOptionPane.YES_NO_CANCEL_OPTION);
     return option;
   }
 
@@ -381,11 +381,11 @@ public abstract class StructureViewerBase extends GStructureViewer
         continue;
       }
       int option = chooseAlignStructureToViewer(pdbId, view);
-      if (option == JOptionPane.CANCEL_OPTION)
+      if (option == JvOptionPane.CANCEL_OPTION)
       {
         return true;
       }
-      else if (option == JOptionPane.YES_OPTION)
+      else if (option == JvOptionPane.YES_OPTION)
       {
         view.useAlignmentPanelForSuperposition(apanel);
         view.addStructure(pdbentry, seq, chains, true, apanel.alignFrame);
@@ -481,19 +481,19 @@ public abstract class StructureViewerBase extends GStructureViewer
       /*
        * the PDB file is already loaded
        */
-      int option = JOptionPane.showInternalConfirmDialog(Desktop.desktop,
+      int option = JvOptionPane.showInternalConfirmDialog(Desktop.desktop,
               MessageManager.formatMessage(
                       "label.pdb_entry_is_already_displayed",
                       new Object[] { pdbId }), MessageManager
                       .formatMessage(
                               "label.map_sequences_to_visible_window",
                               new Object[] { pdbId }),
-              JOptionPane.YES_NO_CANCEL_OPTION);
-      if (option == JOptionPane.CANCEL_OPTION)
+              JvOptionPane.YES_NO_CANCEL_OPTION);
+      if (option == JvOptionPane.CANCEL_OPTION)
       {
         finished = true;
       }
-      else if (option == JOptionPane.YES_OPTION)
+      else if (option == JvOptionPane.YES_OPTION)
       {
         addSequenceMappingsToStructure(seq, chains, apanel, alreadyMapped);
         finished = true;
index 39d9c1d..49fdaf7 100644 (file)
@@ -128,16 +128,16 @@ public class TextColourChooser
       }
     });
 
-    int reply = JOptionPane
+    int reply = JvOptionPane
             .showInternalOptionDialog(
                     ap,
                     bigpanel,
                     MessageManager
                             .getString("label.adjunst_foreground_text_colour_threshold"),
-                    JOptionPane.OK_CANCEL_OPTION,
-                    JOptionPane.QUESTION_MESSAGE, null, null, null);
+                    JvOptionPane.OK_CANCEL_OPTION,
+                    JvOptionPane.QUESTION_MESSAGE, null, null, null);
 
-    if (reply == JOptionPane.CANCEL_OPTION)
+    if (reply == JvOptionPane.CANCEL_OPTION)
     {
       if (sg == null)
       {
index c9c1531..02470d6 100755 (executable)
@@ -456,10 +456,10 @@ public class UserDefinedColours extends GUserDefinedColours implements
   {
     if (isNoSelectionMade())
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .getString("label.no_colour_selection_in_scheme"),
               MessageManager.getString("label.no_colour_selection_warn"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
     }
     else
     {
@@ -502,10 +502,10 @@ public class UserDefinedColours extends GUserDefinedColours implements
   {
     if (isNoSelectionMade())
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .getString("label.no_colour_selection_in_scheme"),
               MessageManager.getString("label.no_colour_selection_warn"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
     }
     UserColourScheme ucs = getSchemeFromButtons();
@@ -809,23 +809,23 @@ public class UserDefinedColours extends GUserDefinedColours implements
   {
     if (schemeName.getText().trim().length() < 1)
     {
-      JOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showInternalMessageDialog(Desktop.desktop, MessageManager
               .getString("label.user_colour_scheme_must_have_name"),
               MessageManager.getString("label.no_name_colour_scheme"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
       return;
     }
 
     if (userColourSchemes != null
             && userColourSchemes.containsKey(schemeName.getText()))
     {
-      int reply = JOptionPane.showInternalConfirmDialog(Desktop.desktop,
+      int reply = JvOptionPane.showInternalConfirmDialog(Desktop.desktop,
               MessageManager.formatMessage(
                       "label.colour_scheme_exists_overwrite", new Object[] {
                           schemeName.getText(), schemeName.getText() }),
               MessageManager.getString("label.duplicate_scheme_name"),
-              JOptionPane.YES_NO_OPTION);
-      if (reply != JOptionPane.YES_OPTION)
+              JvOptionPane.YES_NO_OPTION);
+      if (reply != JvOptionPane.YES_OPTION)
       {
         return;
       }
index eb38ee6..5e5d965 100644 (file)
@@ -142,15 +142,15 @@ public class UserQuestionnaireCheck implements Runnable
                 + qid + "&rid=" + rid;
         jalview.bin.Cache.log.info("Prompting user for questionnaire at "
                 + qurl);
-        int reply = JOptionPane
+        int reply = JvOptionPane
                 .showInternalConfirmDialog(Desktop.desktop, MessageManager
                         .getString("label.jalview_new_questionnaire"),
                         MessageManager
                                 .getString("label.jalview_user_survey"),
-                        JOptionPane.YES_NO_OPTION,
-                        JOptionPane.QUESTION_MESSAGE);
+                        JvOptionPane.YES_NO_OPTION,
+                        JvOptionPane.QUESTION_MESSAGE);
 
-        if (reply == JOptionPane.YES_OPTION)
+        if (reply == JvOptionPane.YES_OPTION)
         {
           jalview.bin.Cache.log.debug("Opening " + qurl);
           jalview.util.BrowserLauncher.openURL(qurl);
index afb6df4..75ddba5 100644 (file)
@@ -174,7 +174,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
           }
         } catch (InvalidSessionDocumentException e)
         {
-          JOptionPane
+          JvOptionPane
                   .showInternalMessageDialog(
                           Desktop.desktop,
 
@@ -182,7 +182,7 @@ public class VamsasApplication implements SelectionSource, VamsasSource
                                   .getString("label.vamsas_doc_couldnt_be_opened_as_new_session"),
                           MessageManager
                                   .getString("label.vamsas_document_import_failed"),
-                          JOptionPane.ERROR_MESSAGE);
+                          JvOptionPane.ERROR_MESSAGE);
 
         }
       }
@@ -665,15 +665,15 @@ public class VamsasApplication implements SelectionSource, VamsasSource
                 {
                   Cache.log
                           .debug("Asking user if the vamsas session should be stored.");
-                  int reply = JOptionPane
+                  int reply = JvOptionPane
                           .showInternalConfirmDialog(
                                   Desktop.desktop,
                                   "The current VAMSAS session has unsaved data - do you want to save it ?",
                                   "VAMSAS Session Shutdown",
-                                  JOptionPane.YES_NO_OPTION,
-                                  JOptionPane.QUESTION_MESSAGE);
+                                  JvOptionPane.YES_NO_OPTION,
+                                  JvOptionPane.QUESTION_MESSAGE);
 
-                  if (reply == JOptionPane.YES_OPTION)
+                  if (reply == JvOptionPane.YES_OPTION)
                   {
                     Cache.log.debug("Prompting for vamsas store filename.");
                     Desktop.instance.vamsasSave_actionPerformed(null);
index dd0e6c2..f650807 100644 (file)
@@ -707,8 +707,8 @@ public class WebserviceInfo extends GWebserviceInfo implements
     {
       public void run()
       {
-        JOptionPane.showInternalMessageDialog(Desktop.desktop, message,
-                title, JOptionPane.WARNING_MESSAGE);
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop, message,
+                title, JvOptionPane.WARNING_MESSAGE);
 
       }
     });
index c4d215e..17c0760 100644 (file)
@@ -61,7 +61,6 @@ import javax.swing.JComboBox;
 import javax.swing.JDialog;
 import javax.swing.JFrame;
 import javax.swing.JLabel;
-import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JScrollPane;
 import javax.swing.JSplitPane;
@@ -233,6 +232,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
     frame.validate();
     javax.swing.SwingUtilities.invokeLater(new Runnable()
     {
+      @Override
       public void run()
       {
         // jobPanel.setDividerLocation(0.25);
@@ -272,6 +272,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             new ActionListener()
             {
 
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 update_actionPerformed(e);
@@ -283,6 +284,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             new ActionListener()
             {
 
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 delete_actionPerformed(e);
@@ -294,6 +296,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             new ActionListener()
             {
 
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 create_actionPerformed(e);
@@ -305,6 +308,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             new ActionListener()
             {
 
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 revert_actionPerformed(e);
@@ -315,6 +319,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             MessageManager.getString("label.start_job_current_settings"),
             new ActionListener()
             {
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 startjob_actionPerformed(e);
@@ -325,6 +330,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
             MessageManager.getString("label.cancel_job_close_dialog"),
             new ActionListener()
             {
+              @Override
               public void actionPerformed(ActionEvent e)
               {
                 canceljob_actionPerformed(e);
@@ -736,6 +742,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
     validate();
   }
 
+  @Override
   public void argSetModified(Object modifiedElement, boolean b)
   {
     if (settingDialog)
@@ -827,6 +834,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
     settingDialog = stn;
   }
 
+  @Override
   public void refreshParamLayout()
   {
     // optsAndparams.setPreferredSize(null);
@@ -1113,40 +1121,47 @@ public class WsJobParameters extends JPanel implements ItemListener,
             jf.addWindowListener(new WindowListener()
             {
 
+              @Override
               public void windowActivated(WindowEvent e)
               {
                 // TODO Auto-generated method stub
 
               }
 
+              @Override
               public void windowClosed(WindowEvent e)
               {
               }
 
+              @Override
               public void windowClosing(WindowEvent e)
               {
                 thr.interrupt();
 
               }
 
+              @Override
               public void windowDeactivated(WindowEvent e)
               {
                 // TODO Auto-generated method stub
 
               }
 
+              @Override
               public void windowDeiconified(WindowEvent e)
               {
                 // TODO Auto-generated method stub
 
               }
 
+              @Override
               public void windowIconified(WindowEvent e)
               {
                 // TODO Auto-generated method stub
 
               }
 
+              @Override
               public void windowOpened(WindowEvent e)
               {
                 // TODO Auto-generated method stub
@@ -1316,6 +1331,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
 
   String curSetName = null;
 
+  @Override
   public void itemStateChanged(ItemEvent e)
   {
     if (e.getSource() == setName && e.getStateChange() == e.SELECTED)
@@ -1334,6 +1350,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
       }
       javax.swing.SwingUtilities.invokeLater(new Runnable()
       {
+        @Override
         public void run()
         {
           doPreferenceComboStateChange(setname);
@@ -1355,14 +1372,14 @@ public class WsJobParameters extends JPanel implements ItemListener,
       }
       settingDialog = true;
       System.out.println("Prompting to save " + lsetname);
-      if (javax.swing.JOptionPane
+      if (JvOptionPane
               .showConfirmDialog(
                       this,
                       "Parameter set '"
                               + lsetname
                               + "' is modifed, and your changes will be lost.\nReally change preset ?",
                       "Warning: Unsaved Changes",
-                      javax.swing.JOptionPane.OK_CANCEL_OPTION) != JOptionPane.OK_OPTION)
+                      JvOptionPane.OK_CANCEL_OPTION) != JvOptionPane.OK_OPTION)
       {
         // revert the combobox to the current item
         settingDialog = true;
@@ -1414,6 +1431,7 @@ public class WsJobParameters extends JPanel implements ItemListener,
    */
   String lastDescrText = null;
 
+  @Override
   public void actionPerformed(ActionEvent e)
   {
     if (e.getSource() instanceof Component)
@@ -1434,12 +1452,13 @@ public class WsJobParameters extends JPanel implements ItemListener,
           settingDialog = false;
           javax.swing.SwingUtilities.invokeLater(new Runnable()
           {
+            @Override
             public void run()
             {
-              JOptionPane.showMessageDialog(ourframe, MessageManager
+              JvOptionPane.showMessageDialog(ourframe, MessageManager
                       .getString("label.invalid_name_preset_exists"),
                       MessageManager.getString("label.invalid_name"),
-                      JOptionPane.WARNING_MESSAGE);
+                      JvOptionPane.WARNING_MESSAGE);
             }
           });
 
@@ -1475,16 +1494,19 @@ public class WsJobParameters extends JPanel implements ItemListener,
     }
   }
 
+  @Override
   public void insertUpdate(DocumentEvent e)
   {
     checkDescrModified();
   }
 
+  @Override
   public void removeUpdate(DocumentEvent e)
   {
     checkDescrModified();
   }
 
+  @Override
   public void changedUpdate(DocumentEvent e)
   {
     checkDescrModified();
index b6a7672..f0487e3 100644 (file)
@@ -294,9 +294,9 @@ public class WsParamSetManager implements ParamManager
       File pfile = new File(filename);
       if (pfile.exists() && pfile.canWrite())
       {
-        if (JOptionPane.showConfirmDialog(Desktop.instance,
+        if (JvOptionPane.showConfirmDialog(Desktop.instance,
                 "Delete the preset's file, too ?", "Delete User Preset ?",
-                JOptionPane.OK_CANCEL_OPTION) == JOptionPane.OK_OPTION)
+                JvOptionPane.OK_CANCEL_OPTION) == JvOptionPane.OK_OPTION)
         {
           pfile.delete();
         }
index 6ec25b2..165e8f2 100644 (file)
@@ -459,11 +459,11 @@ public class WsPreferences extends GWsPreferences
     pane12.add(urltf, BorderLayout.EAST);
     panel.add(pane12, BorderLayout.NORTH);
     boolean valid = false;
-    int resp = JOptionPane.CANCEL_OPTION;
+    int resp = JvOptionPane.CANCEL_OPTION;
     while (!valid
-            && (resp = JOptionPane.showInternalConfirmDialog(
+            && (resp = JvOptionPane.showInternalConfirmDialog(
                     Desktop.desktop, panel, title,
-                    JOptionPane.OK_CANCEL_OPTION)) == JOptionPane.OK_OPTION)
+                    JvOptionPane.OK_CANCEL_OPTION)) == JvOptionPane.OK_OPTION)
     {
       try
       {
@@ -480,18 +480,18 @@ public class WsPreferences extends GWsPreferences
       } catch (Exception e)
       {
         valid = false;
-        JOptionPane.showInternalMessageDialog(Desktop.desktop,
+        JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                 MessageManager.getString("label.invalid_url"));
       }
     }
-    if (valid && resp == JOptionPane.OK_OPTION)
+    if (valid && resp == JvOptionPane.OK_OPTION)
     {
-      int validate = JOptionPane.showInternalConfirmDialog(Desktop.desktop,
+      int validate = JvOptionPane.showInternalConfirmDialog(Desktop.desktop,
               MessageManager.getString("info.validate_jabaws_server"),
               MessageManager.getString("label.test_server"),
-              JOptionPane.YES_NO_OPTION);
+              JvOptionPane.YES_NO_OPTION);
 
-      if (validate == JOptionPane.OK_OPTION)
+      if (validate == JvOptionPane.OK_OPTION)
       {
         if (Jws2Discoverer.testServiceUrl(foo))
         {
@@ -499,22 +499,22 @@ public class WsPreferences extends GWsPreferences
         }
         else
         {
-          int opt = JOptionPane
+          int opt = JvOptionPane
                   .showInternalOptionDialog(
                           Desktop.desktop,
                           "The Server  '"
                                   + foo.toString()
                                   + "' failed validation,\ndo you want to add it anyway? ",
                           "Server Validation Failed",
-                          JOptionPane.YES_NO_OPTION,
-                          JOptionPane.INFORMATION_MESSAGE, null, null, null);
-          if (opt == JOptionPane.YES_OPTION)
+                          JvOptionPane.YES_NO_OPTION,
+                          JvOptionPane.INFORMATION_MESSAGE, null, null, null);
+          if (opt == JvOptionPane.YES_OPTION)
           {
             return foo.toString();
           }
           else
           {
-            JOptionPane
+            JvOptionPane
                     .showInternalMessageDialog(
                             Desktop.desktop,
                             MessageManager
index b449d19..becc434 100755 (executable)
@@ -33,6 +33,7 @@ import jalview.gui.AlignFrame;
 import jalview.gui.AlignViewport;
 import jalview.gui.Desktop;
 import jalview.gui.Jalview2XML;
+import jalview.gui.JvOptionPane;
 import jalview.json.binding.biojson.v1.ColourSchemeMapper;
 import jalview.schemes.ColourSchemeI;
 import jalview.structure.StructureSelectionManager;
@@ -41,7 +42,6 @@ import jalview.util.MessageManager;
 import java.util.StringTokenizer;
 import java.util.Vector;
 
-import javax.swing.JOptionPane;
 import javax.swing.SwingUtilities;
 
 public class FileLoader implements Runnable
@@ -273,13 +273,13 @@ public class FileLoader implements Runnable
                 + "\" has null or unidentifiable data content!");
         if (!Jalview.isHeadlessMode())
         {
-          javax.swing.JOptionPane.showInternalMessageDialog(
+          JvOptionPane.showInternalMessageDialog(
                   Desktop.desktop,
                   MessageManager.getString("label.couldnt_read_data")
                           + " in " + file + "\n"
                           + AppletFormatAdapter.SUPPORTED_FORMATS,
                   MessageManager.getString("label.couldnt_read_data"),
-                  JOptionPane.WARNING_MESSAGE);
+                  JvOptionPane.WARNING_MESSAGE);
         }
         return;
       }
@@ -464,10 +464,10 @@ public class FileLoader implements Runnable
               @Override
               public void run()
               {
-                JOptionPane.showInternalMessageDialog(Desktop.desktop,
+                JvOptionPane.showInternalMessageDialog(Desktop.desktop,
                         errorMessage, MessageManager
                                 .getString("label.error_loading_file"),
-                        JOptionPane.WARNING_MESSAGE);
+                        JvOptionPane.WARNING_MESSAGE);
               }
             });
           }
@@ -491,12 +491,12 @@ public class FileLoader implements Runnable
           @Override
           public void run()
           {
-            javax.swing.JOptionPane.showInternalMessageDialog(
+            JvOptionPane.showInternalMessageDialog(
                     Desktop.desktop, MessageManager.formatMessage(
                             "label.problems_opening_file",
                             new String[] { file }), MessageManager
                             .getString("label.file_open_error"),
-                    javax.swing.JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
         });
       }
@@ -513,12 +513,12 @@ public class FileLoader implements Runnable
           @Override
           public void run()
           {
-            javax.swing.JOptionPane.showInternalMessageDialog(
+            JvOptionPane.showInternalMessageDialog(
                     Desktop.desktop, MessageManager.formatMessage(
                             "warn.out_of_memory_loading_file", new String[]
                             { file }), MessageManager
                             .getString("label.out_of_memory"),
-                    javax.swing.JOptionPane.WARNING_MESSAGE);
+                    JvOptionPane.WARNING_MESSAGE);
           }
         });
       }
index 1ea6795..de2c740 100755 (executable)
@@ -21,6 +21,7 @@
 //////////////////////////////////////////////////////////////////
 package jalview.io;
 
+import jalview.gui.JvOptionPane;
 import jalview.util.MessageManager;
 import jalview.util.Platform;
 
@@ -37,7 +38,6 @@ import java.util.Vector;
 import javax.swing.DefaultListCellRenderer;
 import javax.swing.JFileChooser;
 import javax.swing.JList;
-import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JScrollPane;
 import javax.swing.SpringLayout;
@@ -223,12 +223,12 @@ public class JalviewFileChooser extends JFileChooser
     if ((ret == JalviewFileChooser.APPROVE_OPTION)
             && getSelectedFile().exists())
     {
-      int confirm = JOptionPane.showConfirmDialog(parent,
+      int confirm = JvOptionPane.showConfirmDialog(parent,
               MessageManager.getString("label.overwrite_existing_file"),
               MessageManager.getString("label.file_already_exists"),
-              JOptionPane.YES_NO_OPTION);
+              JvOptionPane.YES_NO_OPTION);
 
-      if (confirm != JOptionPane.YES_OPTION)
+      if (confirm != JvOptionPane.YES_OPTION)
       {
         ret = JalviewFileChooser.CANCEL_OPTION;
       }
index 9d9b940..55e72eb 100755 (executable)
@@ -27,6 +27,7 @@ import jalview.datamodel.Sequence;
 import jalview.gui.AlignmentPanel;
 import jalview.gui.CutAndPasteTransfer;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.util.MessageManager;
 
 import java.util.ArrayList;
@@ -35,7 +36,6 @@ import java.util.StringTokenizer;
 import java.util.Vector;
 
 import javax.swing.ImageIcon;
-import javax.swing.JOptionPane;
 
 import uk.ac.ebi.www.Data;
 import uk.ac.ebi.www.InputParams;
@@ -150,11 +150,11 @@ public class WSWUBlastClient
   {
     // This must be outside the run() body as java 1.5
     // will not return any value from the OptionPane to the expired thread.
-    int reply = JOptionPane.showConfirmDialog(Desktop.desktop,
+    int reply = JvOptionPane.showConfirmDialog(Desktop.desktop,
             "Automatically update suggested ids?",
-            "Auto replace sequence ids", JOptionPane.YES_NO_OPTION);
+            "Auto replace sequence ids", JvOptionPane.YES_NO_OPTION);
 
-    if (reply == JOptionPane.YES_OPTION)
+    if (reply == JvOptionPane.YES_OPTION)
     {
       Enumeration keys = suggestedIds.elements();
       while (keys.hasMoreElements())
@@ -211,6 +211,7 @@ public class WSWUBlastClient
       }
     }
 
+    @Override
     public void run()
     {
       while (jobsRunning > 0)
@@ -250,6 +251,7 @@ public class WSWUBlastClient
       this.sequence = sequence;
     }
 
+    @Override
     public void run()
     {
       StartJob();
index af8a172..d2cb5a2 100755 (executable)
@@ -23,6 +23,7 @@ package jalview.jbgui;
 import jalview.analysis.AnnotationSorter.SequenceAnnotationOrder;
 import jalview.api.SplitContainerI;
 import jalview.bin.Cache;
+import jalview.gui.JvOptionPane;
 import jalview.gui.JvSwingUtils;
 import jalview.gui.Preferences;
 import jalview.schemes.ColourSchemeProperty;
@@ -50,7 +51,6 @@ import javax.swing.JLabel;
 import javax.swing.JMenu;
 import javax.swing.JMenuBar;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JRadioButtonMenuItem;
 import javax.swing.JTabbedPane;
@@ -314,13 +314,13 @@ public class GAlignFrame extends JInternalFrame
           {
             radioItem.removeActionListener(radioItem.getActionListeners()[0]);
 
-            int option = JOptionPane.showInternalConfirmDialog(
+            int option = JvOptionPane.showInternalConfirmDialog(
                     jalview.gui.Desktop.desktop, MessageManager
                             .getString("label.remove_from_default_list"),
                     MessageManager
                             .getString("label.remove_user_defined_colour"),
-                    JOptionPane.YES_NO_OPTION);
-            if (option == JOptionPane.YES_OPTION)
+                    JvOptionPane.YES_NO_OPTION);
+            if (option == JvOptionPane.YES_OPTION)
             {
               jalview.gui.UserDefinedColours
                       .removeColourFromDefaults(radioItem.getText());
index 2689946..dbce5f3 100755 (executable)
@@ -20,6 +20,7 @@
  */
 package jalview.jbgui;
 
+import jalview.gui.JvOptionPane;
 import jalview.gui.JvSwingUtils;
 import jalview.util.MessageManager;
 import jalview.util.UrlLink;
@@ -35,7 +36,6 @@ import java.awt.event.KeyEvent;
 
 import javax.swing.BorderFactory;
 import javax.swing.JLabel;
-import javax.swing.JOptionPane;
 import javax.swing.JPanel;
 import javax.swing.JTextField;
 import javax.swing.SwingConstants;
@@ -156,10 +156,10 @@ public class GSequenceLink extends Panel
       return true;
     }
 
-    JOptionPane.showInternalMessageDialog(jalview.gui.Desktop.desktop,
+    JvOptionPane.showInternalMessageDialog(jalview.gui.Desktop.desktop,
             MessageManager.getString("warn.url_must_contain"),
             MessageManager.getString("label.invalid_url"),
-            JOptionPane.WARNING_MESSAGE);
+            JvOptionPane.WARNING_MESSAGE);
     return false;
   }
 
index 7e069e3..676a4b6 100644 (file)
@@ -28,6 +28,7 @@ import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
 import jalview.gui.FeatureSettings;
+import jalview.gui.JvOptionPane;
 import jalview.util.DBRefUtils;
 import jalview.util.MessageManager;
 import jalview.util.UrlLink;
@@ -46,8 +47,6 @@ import java.util.Set;
 import java.util.StringTokenizer;
 import java.util.Vector;
 
-import javax.swing.JOptionPane;
-
 import org.biodas.jdas.client.FeaturesClient;
 import org.biodas.jdas.client.adapters.features.DasGFFAdapter;
 import org.biodas.jdas.client.adapters.features.DasGFFAdapter.GFFAdapter;
@@ -200,21 +199,21 @@ public class DasSequenceFeatureFetcher
     if (checkDbrefs && refCount < sequences.length && uniprotCount > 0)
     {
 
-      int reply = JOptionPane.YES_OPTION;
+      int reply = JvOptionPane.YES_OPTION;
       if (promptFetchDbrefs)
       {
-        reply = JOptionPane
+        reply = JvOptionPane
                 .showInternalConfirmDialog(
                         Desktop.desktop,
                         MessageManager
                                 .getString("info.you_want_jalview_to_find_uniprot_accessions"),
                         MessageManager
                                 .getString("label.find_uniprot_accession_ids"),
-                        JOptionPane.YES_NO_OPTION,
-                        JOptionPane.QUESTION_MESSAGE);
+                        JvOptionPane.YES_NO_OPTION,
+                        JvOptionPane.QUESTION_MESSAGE);
       }
 
-      if (reply == JOptionPane.YES_OPTION)
+      if (reply == JvOptionPane.YES_OPTION)
       {
         Thread thread = new Thread(new FetchDBRefs());
         thread.start();
index 4643119..7258f51 100644 (file)
  */
 package jalview.ws.jws1;
 
+import jalview.gui.JvOptionPane;
 import jalview.util.MessageManager;
 
 import java.util.Hashtable;
 import java.util.StringTokenizer;
 import java.util.Vector;
 
-import javax.swing.JOptionPane;
-
 import ext.vamsas.IRegistry;
 import ext.vamsas.IRegistryServiceLocator;
 import ext.vamsas.RegistryServiceSoapBindingStub;
@@ -255,11 +254,11 @@ public class Discoverer implements Runnable
       {
         if (jalview.gui.Desktop.desktop != null)
         {
-          JOptionPane.showMessageDialog(jalview.gui.Desktop.desktop,
+          JvOptionPane.showMessageDialog(jalview.gui.Desktop.desktop,
                   MessageManager.getString("label.set_proxy_settings"),
                   MessageManager
                           .getString("label.proxy_authorization_failed"),
-                  JOptionPane.WARNING_MESSAGE);
+                  JvOptionPane.WARNING_MESSAGE);
         }
       }
       else
@@ -383,11 +382,13 @@ public class Discoverer implements Runnable
   /**
    * creates a new thread to call discoverServices()
    */
+  @Override
   public void run()
   {
     final Discoverer discoverer = this;
     Thread discoverThread = new Thread()
     {
+      @Override
       public void run()
       {
         discoverer.doDiscovery();
index f13672b..2c05386 100644 (file)
@@ -27,6 +27,7 @@ import jalview.datamodel.SeqCigar;
 import jalview.datamodel.SequenceI;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.WebserviceInfo;
 import jalview.util.MessageManager;
 
@@ -36,7 +37,6 @@ import java.util.Hashtable;
 
 import javax.swing.JMenu;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 
 import ext.vamsas.Jpred;
 import ext.vamsas.JpredServiceLocator;
@@ -323,7 +323,7 @@ public class JPredClient extends WS1Client
 
     } catch (Exception ex)
     {
-      JOptionPane
+      JvOptionPane
               .showMessageDialog(
                       Desktop.desktop,
                       MessageManager
@@ -332,7 +332,7 @@ public class JPredClient extends WS1Client
                                       new String[] { WebServiceName, WsURL }),
                       MessageManager
                               .getString("label.internal_jalview_error"),
-                      JOptionPane.WARNING_MESSAGE);
+                      JvOptionPane.WARNING_MESSAGE);
       wsInfo.setProgressText(MessageManager
               .formatMessage(
                       "label.secondary_structure_prediction_service_couldnt_be_located",
@@ -345,6 +345,7 @@ public class JPredClient extends WS1Client
     return server;
   }
 
+  @Override
   public void attachWSMenuEntry(JMenu wsmenu, final ServiceHandle sh,
           final AlignFrame af)
   {
@@ -352,6 +353,7 @@ public class JPredClient extends WS1Client
     method.setToolTipText(sh.getEndpointURL());
     method.addActionListener(new ActionListener()
     {
+      @Override
       public void actionPerformed(ActionEvent e)
       {
         AlignmentView msa = af.gatherSeqOrMsaForSecStrPrediction();
index aad72b1..5ea553e 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.datamodel.AlignmentView;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.WebserviceInfo;
 import jalview.util.MessageManager;
 
@@ -32,7 +33,6 @@ import java.awt.event.ActionListener;
 
 import javax.swing.JMenu;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 
 import ext.vamsas.MuscleWSServiceLocator;
 import ext.vamsas.MuscleWSSoapBindingStub;
@@ -78,22 +78,22 @@ public class MsaWSClient extends WS1Client
     alignFrame = _alignFrame;
     if (!sh.getAbstractName().equals("MsaWS"))
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.service_called_is_not_msa_service",
                       new String[] { sh.getName() }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
 
     if ((wsInfo = setWebService(sh)) == null)
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.msa_service_is_unknown",
                       new String[] { sh.getName() }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
index 7665fec..92d17e8 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.datamodel.AlignmentView;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.WebserviceInfo;
 import jalview.util.MessageManager;
 
@@ -37,7 +38,6 @@ import java.util.Vector;
 
 import javax.swing.JMenu;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 
 import ext.vamsas.SeqSearchServiceLocator;
 import ext.vamsas.SeqSearchServiceSoapBindingStub;
@@ -84,23 +84,23 @@ public class SeqSearchWSClient extends WS1Client
     // name to service client name
     if (!sh.getAbstractName().equals(this.getServiceActionKey()))
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage(
                       "label.service_called_is_not_seq_search_service",
                       new String[] { sh.getName() }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
 
     if ((wsInfo = setWebService(sh)) == null)
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.seq_search_service_is_unknown",
                       new String[] { sh.getName() }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
index 8fa118d..b723059 100644 (file)
@@ -24,6 +24,7 @@ import jalview.datamodel.AlignmentI;
 import jalview.datamodel.AlignmentView;
 import jalview.gui.AlignFrame;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.JvSwingUtils;
 import jalview.util.MessageManager;
 import jalview.ws.jws2.jabaws2.Jws2Instance;
@@ -37,7 +38,6 @@ import java.util.List;
 
 import javax.swing.JMenu;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 import javax.swing.ToolTipManager;
 
 import compbio.data.msa.MsaWS;
@@ -107,22 +107,22 @@ public class MsaWSClient extends Jws2Client
     if (!(sh.service instanceof MsaWS))
     {
       // redundant at mo - but may change
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.service_called_is_not_msa_service",
                       new String[] { sh.serviceType }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
     server = (MsaWS) sh.service;
     if ((wsInfo = setWebService(sh, false)) == null)
     {
-      JOptionPane.showMessageDialog(Desktop.desktop, MessageManager
+      JvOptionPane.showMessageDialog(Desktop.desktop, MessageManager
               .formatMessage("label.msa_service_is_unknown",
                       new String[] { sh.serviceType }), MessageManager
               .getString("label.internal_jalview_error"),
-              JOptionPane.WARNING_MESSAGE);
+              JvOptionPane.WARNING_MESSAGE);
 
       return;
     }
@@ -180,10 +180,10 @@ public class MsaWSClient extends Jws2Client
     }
     else
     {
-      JOptionPane.showMessageDialog(alignFrame,
+      JvOptionPane.showMessageDialog(alignFrame,
               MessageManager.getString("info.invalid_msa_input_mininfo"),
               MessageManager.getString("info.invalid_msa_notenough"),
-              JOptionPane.INFORMATION_MESSAGE);
+              JvOptionPane.INFORMATION_MESSAGE);
       wsInfo.setVisible(false);
     }
   }
index 2af31bb..4702686 100644 (file)
@@ -67,9 +67,9 @@ public class SequenceAnnotationWSClient extends Jws2Client
     // dan changed! dan test. comment out if conditional
     // if (alignFrame.getViewport().getAlignment().isNucleotide())
     // {
-    // JOptionPane.showMessageDialog(Desktop.desktop, sh.serviceType
+    // JvOptionPane.showMessageDialog(Desktop.desktop, sh.serviceType
     // + " can only be used\nfor amino acid alignments.",
-    // "Wrong type of sequences!", JOptionPane.WARNING_MESSAGE);
+    // "Wrong type of sequences!", JvOptionPane.WARNING_MESSAGE);
     // return;
     //
     // }
index 1fb9259..7fbae89 100644 (file)
@@ -26,6 +26,7 @@ import jalview.gui.AlignFrame;
 import jalview.gui.AlignViewport;
 import jalview.gui.AlignmentPanel;
 import jalview.gui.Desktop;
+import jalview.gui.JvOptionPane;
 import jalview.gui.WebserviceInfo;
 import jalview.io.packed.DataProvider.JvDataType;
 import jalview.util.MessageManager;
@@ -40,7 +41,6 @@ import java.util.Vector;
 
 import javax.swing.JMenu;
 import javax.swing.JMenuItem;
-import javax.swing.JOptionPane;
 import javax.swing.event.MenuEvent;
 import javax.swing.event.MenuListener;
 
@@ -324,7 +324,7 @@ public class RestClient extends WSClient implements WSClientI,
     else
     {
       // TODO: try to tell the user why the job couldn't be started.
-      JOptionPane
+      JvOptionPane
               .showMessageDialog(
                       Desktop.desktop,
                       (jobsthread.hasWarnings() ? jobsthread.getWarnings()
@@ -332,7 +332,7 @@ public class RestClient extends WSClient implements WSClientI,
                                       .getString("label.job_couldnt_be_started_check_input")),
                       MessageManager
                               .getString("label.unable_start_web_service_analysis"),
-                      JOptionPane.WARNING_MESSAGE);
+                      JvOptionPane.WARNING_MESSAGE);
     }
   }