protected void editMetadata() { NetworkMetaDataDialog mdd = new NetworkMetaDataDialog(Cytoscape.getDesktop(), false, Cytoscape.getCurrentNetwork()); mdd.setVisible(true); }
private void okButtonMouseClicked(java.awt.event.MouseEvent evt) { // TODO add your handling code here: try { update(); } catch (JAXBException e1) { logger.warn("Unable to update network metadata", e1); } // Cytoscape.firePropertyChange(Cytoscape.ATTRIBUTES_CHANGED, null, // null); this.dispose(); }
Font titleFont = new Font("SansSerif", Font.BOLD, 14); this.setTitle("Network Metadata Editor"); descriptionTextArea = new javax.swing.JTextArea(); setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE); okButton.setText("Update"); okButton.addMouseListener(new java.awt.event.MouseAdapter() { mainSplitPane.setOrientation(javax.swing.JSplitPane.VERTICAL_SPLIT); metadataTableScrollPane.setViewportView(getMetadataTable()); org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(getContentPane()); getContentPane().setLayout(layout); layout.setHorizontalGroup(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING) .add(org.jdesktop.layout.GroupLayout.TRAILING, .add(okButton).add(cancelButton)) .addContainerGap())); pack();
} else if ((value != null) && (value instanceof Map) && model.getValueAt(row, 0).equals(AttributeBrowser.NETWORK_METADATA)) { NetworkMetaDataDialog mdd = new NetworkMetaDataDialog(Cytoscape.getDesktop(), false, Cytoscape.getCurrentNetwork()); mdd.setLocationRelativeTo(Cytoscape.getDesktop()); mdd.setVisible(true); } else if ((tester != null) && tester.equals(Map.class)) { int idCol = 0;
private void cancelButtonMouseClicked(java.awt.event.MouseEvent evt) { // TODO add your handling code here: this.dispose(); }
/** * Creates new form MetadataDialog * * @throws URISyntaxException */ public NetworkMetaDataDialog(java.awt.Frame parent, boolean modal, CyNetwork network) { super(parent, modal); this.network = network; this.mdp = new MetadataParser(network); metaTM = new NetworkMetaDataTableModel(network); try { metaTM.setTable(); } catch (URISyntaxException e) { // TODO Auto-generated catch block logger.warn("Unable to parse some of the network meta-data", e); } description = metaTM.getDescription(); initComponents(); }