Author: pwang
Date: 2008-09-08 14:37:48 -0700 (Mon, 08 Sep 2008)
New Revision: 14856

Modified:
   
csplugins/trunk/ucsd/pwang/SessionForWebPlugin/src/SessionForWebPlugin/SessionExporterDialog.java
Log:
Remove the species panel

Modified: 
csplugins/trunk/ucsd/pwang/SessionForWebPlugin/src/SessionForWebPlugin/SessionExporterDialog.java
===================================================================
--- 
csplugins/trunk/ucsd/pwang/SessionForWebPlugin/src/SessionForWebPlugin/SessionExporterDialog.java
   2008-09-08 21:35:50 UTC (rev 14855)
+++ 
csplugins/trunk/ucsd/pwang/SessionForWebPlugin/src/SessionForWebPlugin/SessionExporterDialog.java
   2008-09-08 21:37:48 UTC (rev 14856)
@@ -30,12 +30,8 @@
 {
        private JTabbedPane tabbedPane;
        private NetworksTable networksTable;
-       private NetworkSpeciesPanel speciesPanel;
-       
        private JRadioButton filesToDirButton;
        private JRadioButton filesToZipButton;
-       private JRadioButton filesToZipButton_4CellCircuits;
-       
        private JSpinner numNetworksPerRowSpinner;
        private JCheckBox separateIntoPagesCheckBox;
        private JLabel numNetworksPerPageLabel;
@@ -75,25 +71,15 @@
                        tabbedPane.add("Networks", networksScrollPane);
                }
 
-               // Species panel
-               {
-                       speciesPanel = new NetworkSpeciesPanel();
-                       JScrollPane networksScrollPane = new 
JScrollPane(speciesPanel);
-                       tabbedPane.add("Species", speciesPanel);
-               }
-
                // Files panel
                {
                        JLabel filesLabel = new JLabel("Save files:");
                        filesToDirButton = new JRadioButton("To a directory");
                        filesToDirButton.setSelected(true);
                        filesToZipButton = new JRadioButton("As a zip archive");
-                       filesToZipButton_4CellCircuits = new JRadioButton("As a 
zip archive for Cell Circuits web site");
-
                        ButtonGroup filesGroup = new ButtonGroup();
                        filesGroup.add(filesToDirButton);
                        filesGroup.add(filesToZipButton);
-                       filesGroup.add(filesToZipButton_4CellCircuits);
 
                        JPanel filesButtonsPanel = new JPanel(new 
GridBagLayout());
                        
filesButtonsPanel.setBorder(BorderFactory.createEmptyBorder(0,10,0,0));
@@ -111,12 +97,6 @@
                        c.weightx = 1.0;        c.weighty = 0.0;
                        filesButtonsPanel.add(filesToZipButton, c);
 
-                       c.gridx = 0;            c.gridy = 2;
-                       c.gridwidth = 1;        c.gridheight = 1;
-                       c.fill = GridBagConstraints.HORIZONTAL;
-                       c.weightx = 1.0;        c.weighty = 0.0;
-                       filesButtonsPanel.add(filesToZipButton_4CellCircuits, 
c);
-                       
                        JPanel filesPanel = new JPanel(new GridBagLayout());
 
                        c.insets = new Insets(5,5,5,5);
@@ -494,7 +474,7 @@
         * Adds the network to the networks table; this should only be called
         * by the updateNetworksTableActionListener.
         */
-       public void addNetwork(String networkID, String networkName, String 
species, int imageWidth, int imageHeight, boolean hasView)
+       public void addNetwork(String networkID, String networkName, int 
imageWidth, int imageHeight, boolean hasView)
        {
                boolean hasMem = true;
                long memoryUse = ((long) imageWidth) * ((long) imageHeight) * 
4L;
@@ -510,7 +490,7 @@
                else
                        status = NetworksTableItem.STATUS_OK;
 
-               NetworksTableItem item = new NetworksTableItem(networkName, 
species, imageWidth, imageHeight, status);
+               NetworksTableItem item = new NetworksTableItem(networkName, 
imageWidth, imageHeight, status);
                networksTable.addNetwork(networkID, item);
        }
 
@@ -521,11 +501,8 @@
                settings.networks = networksTable.getAllNetworksToExport();
                if (filesToDirButton.isSelected())
                        settings.destination = 
SessionExporterSettings.DESTINATION_DIRECTORY;
-               else if (filesToZipButton.isSelected())
+               else
                        settings.destination = 
SessionExporterSettings.DESTINATION_ZIP_ARCHIVE;
-               else if (filesToZipButton_4CellCircuits.isSelected()) {
-                       settings.destination = 
SessionExporterSettings.DESTINATION_ZIP_ARCHIVE_4CELLCIRCUITS;                  
 
-               }
 
                settings.numNetworksPerRow = ((Number) 
numNetworksPerRowSpinner.getValue()).intValue();
                settings.doSeparateIntoPages = 
separateIntoPagesCheckBox.isSelected();
@@ -636,8 +613,8 @@
  */
 class NetworksTable extends JTable
 {
-       private static final String[] columnNames   = {"Export?", "Network", 
"Species","Image Size", "Status"}; 
-       private static final Class[]  columnClasses = { Boolean.class, 
String.class,String.class, String.class, String.class };
+       private static final String[] columnNames   = {"Export?",     
"Network",    "Image Size", "Status"}; 
+       private static final Class[]  columnClasses = { Boolean.class, 
String.class, String.class, String.class };
 
        private ActionListener updateListener;
        private LinkedList<NetworksTableItem> tableItems = new 
LinkedList<NetworksTableItem>();
@@ -646,7 +623,7 @@
        public NetworksTable()
        {
                setModel(new NetworksTableModel());
-               getColumnModel().getColumn(4).setCellRenderer(new 
StatusCellRenderer());
+               getColumnModel().getColumn(3).setCellRenderer(new 
StatusCellRenderer());
                getColumnModel().getColumn(0).setMaxWidth(60);
                addMouseListener(new NetworksTableMouseListener());
                addMouseMotionListener(new NetworksTableMouseMotionListener());
@@ -722,8 +699,6 @@
                        else if (col == 1)
                                return item.getNetworkName();
                        else if (col == 2)
-                               return item.getSpecies();
-                       else if (col == 3)
                                return item.getImageSize();
                        else
                                return null;
@@ -819,15 +794,13 @@
        private boolean enabled;
        private boolean export;
        private String networkName;
-       private String species;
        private int imageWidth;
        private int imageHeight;
        private byte status;
 
-       public NetworksTableItem(String networkName, String species, int 
imageWidth, int imageHeight, byte status)
+       public NetworksTableItem(String networkName, int imageWidth, int 
imageHeight, byte status)
        {
                this.networkName = networkName;
-               this.species = species;         
                this.imageWidth = imageWidth;
                this.imageHeight = imageHeight;
                this.status = status;
@@ -867,11 +840,6 @@
                return networkName;
        }
 
-       public String getSpecies()
-       {
-               return species;
-       }
-
        public String getImageSize()
        {
                if (status == STATUS_NO_VIEW)
@@ -1024,4 +992,3 @@
                setVisible(true);
        }
 }
-


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"cytoscape-cvs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cytoscape-cvs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to