refactored VamsasClient to jalview.gui, and created Vamsas session menu.
[jalview.git] / src / jalview / jbgui / GDesktop.java
index 65ef8dc..499efd5 100755 (executable)
@@ -36,6 +36,7 @@ public class GDesktop extends JFrame
     JMenuBar DesktopMenubar = new JMenuBar();\r
     JMenu FileMenu = new JMenu();\r
     JMenu HelpMenu = new JMenu();\r
+    protected JMenu VamsasMenu = new JMenu();\r
     JMenuItem inputLocalFileMenuItem = new JMenuItem();\r
     JMenuItem inputURLMenuItem = new JMenuItem();\r
     JMenuItem inputTextboxMenuItem = new JMenuItem();\r
@@ -48,8 +49,11 @@ public class GDesktop extends JFrame
     JMenuItem saveState = new JMenuItem();\r
     JMenuItem loadState = new JMenuItem();\r
     JMenu jMenu1 = new JMenu();\r
+  protected JMenuItem vamsasLoad = new JMenuItem();\r
+  JMenuItem inputSequence = new JMenuItem();\r
+  protected JMenuItem vamsasStop = new JMenuItem();\r
 \r
-    /**\r
+  /**\r
      * Creates a new GDesktop object.\r
      */\r
     public GDesktop()\r
@@ -75,6 +79,9 @@ public class GDesktop extends JFrame
         FileMenu.setMnemonic('F');\r
         FileMenu.setText("File");\r
         HelpMenu.setText("Help");\r
+        VamsasMenu.setText("Vamsas");\r
+        VamsasMenu.setMnemonic('V');\r
+        VamsasMenu.setToolTipText("Share data with other vamsas applications.");\r
         inputLocalFileMenuItem.setMnemonic('L');\r
         inputLocalFileMenuItem.setText("from File");\r
         inputLocalFileMenuItem.addActionListener(new java.awt.event.ActionListener()\r
@@ -158,24 +165,53 @@ public class GDesktop extends JFrame
             });\r
         jMenu1.setMnemonic('I');\r
         jMenu1.setText("Input Alignment");\r
-        DesktopMenubar.add(FileMenu);\r
+    vamsasLoad.setText("Start Vamsas Session...");\r
+    vamsasLoad.setVisible(true);\r
+    vamsasLoad.addActionListener(new ActionListener()\r
+    {\r
+      public void actionPerformed(ActionEvent e)\r
+      {\r
+        vamsasLoad_actionPerformed(e);\r
+      }\r
+    });\r
+    inputSequence.setText("Fetch Sequence(s)...");\r
+    inputSequence.addActionListener(new ActionListener()\r
+    {\r
+      public void actionPerformed(ActionEvent e)\r
+      {\r
+        inputSequence_actionPerformed(e);\r
+      }\r
+    });\r
+    vamsasStop.setText("Stop Vamsas Session");\r
+    vamsasStop.setVisible(false);\r
+    vamsasStop.addActionListener(new ActionListener()\r
+    {\r
+      public void actionPerformed(ActionEvent e)\r
+      {\r
+        vamsasStop_actionPerformed(e);\r
+      }\r
+    });    DesktopMenubar.add(FileMenu);\r
         DesktopMenubar.add(toolsMenu);\r
+        DesktopMenubar.add(VamsasMenu);\r
         DesktopMenubar.add(HelpMenu);\r
         DesktopMenubar.add(windowMenu);\r
         FileMenu.addSeparator();\r
         FileMenu.add(jMenu1);\r
-        FileMenu.addSeparator();\r
+    FileMenu.add(inputSequence);\r
+    FileMenu.addSeparator();\r
         FileMenu.add(saveState);\r
         FileMenu.add(loadState);\r
-        FileMenu.addSeparator();\r
-        FileMenu.add(quit);\r
+    FileMenu.addSeparator();\r
+    FileMenu.add(quit);\r
         HelpMenu.add(aboutMenuItem);\r
         HelpMenu.add(documentationMenuItem);\r
+        VamsasMenu.add(vamsasLoad);\r
+        VamsasMenu.add(vamsasStop);\r
         toolsMenu.add(preferences);\r
         jMenu1.add(inputLocalFileMenuItem);\r
         jMenu1.add(inputURLMenuItem);\r
         jMenu1.add(inputTextboxMenuItem);\r
-    }\r
+      }\r
 \r
     /**\r
      * DOCUMENT ME!\r
@@ -273,4 +309,18 @@ public class GDesktop extends JFrame
     public void loadJalviewAlign_actionPerformed(ActionEvent e)\r
     {\r
     }\r
+\r
+  public void vamsasLoad_actionPerformed(ActionEvent e)\r
+  {\r
+\r
+  }\r
+\r
+  public void inputSequence_actionPerformed(ActionEvent e)\r
+  {\r
+\r
+  }\r
+  public void vamsasStop_actionPerformed(ActionEvent e)\r
+  {\r
+\r
+  }\r
 }\r