Skip to content
Snippets Groups Projects
Commit eba7f879 authored by Olivier Langella's avatar Olivier Langella
Browse files

refresh peptide list is OK

parent 42719ef7
No related branches found
No related tags found
No related merge requests found
......@@ -108,9 +108,10 @@ void PeptideListWindow::setProteinMatch(IdentificationGroup * p_identification_g
_p_identification_group = p_identification_group;
_p_protein_match = p_protein_match;
_peptide_table_model_p->setProteinMatch( p_protein_match);
_p_proxy_model->setSourceModel(_peptide_table_model_p);
//_p_proxy_model->setSourceModel(_peptide_table_model_p);
ui->description_label->setText(p_protein_match->getProteinXtpSp().get()->getDescription());
ui->accession_label->setText(p_protein_match->getProteinXtpSp().get()->getAccession());
updateStatusBar();
}
}
......
......@@ -60,7 +60,7 @@ ProteinMatch * PeptideTableModel::getProteinMatch() {
int PeptideTableModel::rowCount(const QModelIndex &parent ) const {
if (_p_protein_match != nullptr) {
//qDebug() << "PeptideTableModel::rowCount(const QModelIndex &parent ) " << _p_protein_match->getPeptideMatchList().size();
return _p_protein_match->getPeptideMatchList().size();
return (int) _p_protein_match->getPeptideMatchList().size();
}
return 0;
}
......
......@@ -169,22 +169,6 @@ bool ProteinTableProxyModel::lessThan(const QModelIndex & left, const QModelInde
return leftData.toDouble() < rightData.toDouble();
}
return leftData.toString() < rightData.toString();
//if (leftData.type() == QVariant::DateTime) {
// return leftData.toDateTime() < rightData.toDateTime();
//} else {
// static QRegExp emailPattern("[\\w\\.]*@[\\w\\.]*)");
/*
QString leftString = leftData.toString();
if(left.column() == 1 && emailPattern.indexIn(leftString) != -1)
leftString = emailPattern.cap(1);
QString rightString = rightData.toString();
if(right.column() == 1 && emailPattern.indexIn(rightString) != -1)
rightString = emailPattern.cap(1);
return QString::localeAwareCompare(leftString, rightString) < 0;
*/
// }
}
QVariant ProteinTableProxyModel::headerData(int section, Qt::Orientation orientation,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment