Skip to content

Commit

Permalink
Re #7820. Fixing bug in sorting columns.
Browse files Browse the repository at this point in the history
  • Loading branch information
peterfpeterson committed Aug 27, 2013
1 parent 002930b commit efc9e2e
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions Code/Mantid/MantidQt/SliceViewer/src/QPeaksTableModel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -373,10 +373,15 @@ namespace MantidQt
const bool isSortable = m_sortableColumns[columnName];
if(isSortable)
{
// TODO raise event and propagate through to Proper presenter.
peaksSorted(columnName.toStdString(), order== Qt::AscendingOrder);

emit layoutChanged(); //This should tell the view that the data has changed.
std::string rationalName(columnName.toStdString());
if (columnName == QPeaksTableModel::INT)
rationalName = "Intens";
else if (columnName == QPeaksTableModel::RUNNUMBER)
rationalName = "RunNumber";
// TODO raise event and propagate through to Proper presenter.
peaksSorted(rationalName, order== Qt::AscendingOrder);

emit layoutChanged(); //This should tell the view that the data has changed.
}
}
}
Expand Down

0 comments on commit efc9e2e

Please sign in to comment.