Package com.compomics.util.gui.tablemodels

Examples of com.compomics.util.gui.tablemodels.SelfUpdatingTableModel


            }

            for (int row = 0; row < selectedRows.length; row++) {

                int currentRow = selectedRows[row];
                SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
                int proteinIndex = tableModel.getViewIndex(currentRow);
                String proteinKey = proteinKeys.get(proteinIndex);
                ProteinMatch proteinMatch = peptideShakerGUI.getIdentification().getProteinMatch(proteinKey);

                try {
                    peptideKeys = peptideShakerGUI.getIdentificationFeaturesGenerator().getSortedPeptideKeys(proteinKey);
View Full Code Here


     * @return the row of the desired protein
     */
    private int getProteinRow(String proteinKey) {
        int modelIndex = proteinKeys.indexOf(proteinKey);
        if (modelIndex >= 0) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            return tableModel.getRowNumber(modelIndex);
        } else {
            return -1;
        }
    }
View Full Code Here

        int row = proteinTable.getSelectedRow();
        int column = proteinTable.getSelectedColumn();

        if (row != -1) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            int proteinIndex = tableModel.getViewIndex(row);

            if (proteinIndex != -1) {
                // remember the selection
                newItemSelection();
                updatePlots();
View Full Code Here

    private void proteinTableKeyReleased(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_proteinTableKeyReleased

        int row = proteinTable.getSelectedRow();

        if (row != -1) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            int proteinIndex = tableModel.getViewIndex(row);

            if (proteinIndex != -1) {
                // remember the selection
                newItemSelection();
                updatePlots();
View Full Code Here

        String proteinKey = PeptideShakerGUI.NO_SELECTION;
        String peptideKey = PeptideShakerGUI.NO_SELECTION;
        String psmKey = PeptideShakerGUI.NO_SELECTION;

        if (proteinTable.getSelectedRow() != -1) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            proteinKey = proteinKeys.get(tableModel.getViewIndex(proteinTable.getSelectedRow()));

            // try to select the "best" peptide for the selected peptide
            peptideKey = peptideShakerGUI.getDefaultPeptideSelection(proteinKey);

            // try to select the "best" psm for the selected peptide
View Full Code Here

        int column = proteinTable.getSelectedColumn();

        int proteinIndex = -1;

        if (row != -1) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            proteinIndex = tableModel.getViewIndex(row);
        }

        if (evt == null || (evt.getButton() == MouseEvent.BUTTON1 && (proteinIndex != -1 && column != -1))) {

            if (proteinIndex != -1) {
View Full Code Here

                    }
                }

                // open the protein inference at the petide level dialog
                if (column == peptideTable.getColumn("PI").getModelIndex() && evt != null && evt.getButton() == MouseEvent.BUTTON1) {
                    SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
                    int proteinIndex = tableModel.getViewIndex(proteinTable.getSelectedRow());
                    String proteinKey = proteinKeys.get(proteinIndex);
                    String peptideKey = peptideTableMap.get(getPeptideIndex(row));
                    new ProteinInferencePeptideLevelDialog(peptideShakerGUI, true, peptideKey, proteinKey);
                }
            }
View Full Code Here

                            null, selectedProteins, true, false, true, true, true,
                            true, true, true, true, false, true,
                            true, true, true, true, true, false, true, false, false, false, true, true);
                } else if (tableIndex == TableIndex.PEPTIDE_TABLE) {
                    ArrayList<String> selectedPeptides = getDisplayedPeptides();
                    SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
                    int proteinIndex = tableModel.getViewIndex(proteinTable.getSelectedRow());
                    String proteinKey = proteinKeys.get(proteinIndex);
                    outputGenerator.getPeptidesOutput(
                            null, selectedPeptides, peptidePdbArray, true, false, true, true, true, true, true,
                            true, true, true, true, true, true, true, true, false, false, false, proteinKey, true);
                } else if (tableIndex == TableIndex.PDB_MATCHES || tableIndex == TableIndex.PDB_CHAINS) {
View Full Code Here

        String proteinKey = PeptideShakerGUI.NO_SELECTION;
        String peptideKey = PeptideShakerGUI.NO_SELECTION;
        String psmKey = peptideShakerGUI.getSelectedPsmKey();

        if (proteinTable.getSelectedRow() != -1) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            int proteinIndex = tableModel.getViewIndex(proteinTable.getSelectedRow());
            proteinKey = proteinKeys.get(proteinIndex);
        }
        if (peptideTable.getSelectedRow() != -1) {
            peptideKey = peptideTableMap.get(getPeptideIndex(peptideTable.getSelectedRow()));
        }
View Full Code Here

     * @return the row of the desired protein
     */
    private int getProteinRow(String proteinKey) {
        int modelIndex = proteinKeys.indexOf(proteinKey);
        if (modelIndex >= 0) {
            SelfUpdatingTableModel tableModel = (SelfUpdatingTableModel) proteinTable.getModel();
            return tableModel.getRowNumber(modelIndex);
        } else {
            return -1;
        }
    }
View Full Code Here

TOP

Related Classes of com.compomics.util.gui.tablemodels.SelfUpdatingTableModel

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.