All optionpane messages must be added to Desktop.desktop
authoramwaterhouse <Andrew Waterhouse>
Fri, 17 Dec 2004 15:14:22 +0000 (15:14 +0000)
committeramwaterhouse <Andrew Waterhouse>
Fri, 17 Dec 2004 15:14:22 +0000 (15:14 +0000)
src/jalview/gui/Desktop.java

index 7a75379..889227f 100755 (executable)
@@ -148,7 +148,7 @@ public class Desktop extends jalview.jbgui.GDesktop
 \r
    }\r
    else\r
-     JOptionPane.showInternalMessageDialog(this,  "Couldn't open file.\n"\r
+     JOptionPane.showInternalMessageDialog(Desktop.desktop,  "Couldn't open file.\n"\r
                           + "Formats currently supported are\n"\r
                           + "Fasta, MSF, Clustal, BLC, PIR, MSP or PFAM"\r
                           ,"Error loading file",\r
@@ -158,7 +158,7 @@ public class Desktop extends jalview.jbgui.GDesktop
 \r
  public void inputURLMenuItem_actionPerformed(ActionEvent e)\r
  {\r
-   String url = JOptionPane.showInternalInputDialog(this,"Enter url of input file",\r
+   String url = JOptionPane.showInternalInputDialog(Desktop.desktop,"Enter url of input file",\r
                                             "Input alignment from URL",\r
                                             JOptionPane.QUESTION_MESSAGE);\r
    if (url == null)\r
@@ -169,7 +169,7 @@ public class Desktop extends jalview.jbgui.GDesktop
    System.out.println(format +" format");\r
    if (format.equals("URL NOT FOUND"))\r
    {\r
-     JOptionPane.showInternalMessageDialog(this,"Couldn't locate " + url,\r
+     JOptionPane.showInternalMessageDialog(Desktop.desktop,"Couldn't locate " + url,\r
                                    "URL not found",\r
                                    JOptionPane.WARNING_MESSAGE);\r
      return;\r
@@ -181,7 +181,7 @@ public class Desktop extends jalview.jbgui.GDesktop
  public void inputTextboxMenuItem_actionPerformed(ActionEvent e)\r
  {\r
    CutAndPasteTransfer cap = new CutAndPasteTransfer(true);\r
-   int accept =  JOptionPane.showInternalOptionDialog(desktop, cap, "Cut & paste Alignment File",\r
+   int accept =  JOptionPane.showInternalOptionDialog(Desktop.desktop, cap, "Cut & paste Alignment File",\r
                                        JOptionPane.YES_NO_CANCEL_OPTION,\r
                                        JOptionPane.PLAIN_MESSAGE,\r
                                        null,\r
@@ -204,7 +204,7 @@ public class Desktop extends jalview.jbgui.GDesktop
         af.statusBar.setText("Successfully pasted alignment file");\r
       }\r
       else\r
-        JOptionPane.showInternalMessageDialog(this, "Couldn't read the pasted text.\n"\r
+        JOptionPane.showInternalMessageDialog(Desktop.desktop, "Couldn't read the pasted text.\n"\r
                                       +"Formats currently supported are\n"\r
                                       +"Fasta, MSF, Clustal, BLC, PIR, MSP or PFAM",\r
                                       "Error parsing text", JOptionPane.WARNING_MESSAGE);\r
@@ -232,7 +232,7 @@ public class Desktop extends jalview.jbgui.GDesktop
 \r
  public void aboutMenuItem_actionPerformed(ActionEvent e)\r
  {\r
-   JOptionPane.showInternalMessageDialog(desktop,\r
+   JOptionPane.showInternalMessageDialog(Desktop.desktop,\r
                                          "JalView 2005"\r
                                        +"\nAuthors:  Michele Clamp, James Cuff, Steve Searle, Andrew Waterhouse and Geoff Barton."\r
                                        +"\nCurrent development managed by Andrew Waterhouse; Barton Group, University of Dundee."\r