Skip to content

Commit

Permalink
valgrind: improve resizing behaviour of costview columns
Browse files Browse the repository at this point in the history
Change-Id: I372f840a78d220f66c91de229b8b7eef99bc92c6
Reviewed-by: hjk <qthjk@ovi.com>
  • Loading branch information
hjk committed Aug 22, 2012
1 parent 73d5f55 commit c107b10
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/plugins/valgrind/callgrindcostview.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,17 +98,13 @@ void CostView::setModel(QAbstractItemModel *model)
headerView->setStretchLastSection(false);

if (qobject_cast<CallModel *>(model)) {
headerView->setResizeMode(CallModel::CalleeColumn, QHeaderView::Stretch);
headerView->setResizeMode(CallModel::CallerColumn, QHeaderView::Stretch);
headerView->setResizeMode(CallModel::CallsColumn, QHeaderView::ResizeToContents);
headerView->setResizeMode(CallModel::CostColumn, QHeaderView::ResizeToContents);
setItemDelegateForColumn(CallModel::CalleeColumn, d->m_nameDelegate);
setItemDelegateForColumn(CallModel::CallerColumn, d->m_nameDelegate);
setItemDelegateForColumn(CallModel::CostColumn, d->m_costDelegate);
} else if (qobject_cast<DataModel *>(model)) {
headerView->setResizeMode(DataModel::InclusiveCostColumn, QHeaderView::ResizeToContents);
headerView->setResizeMode(DataModel::LocationColumn, QHeaderView::Stretch);
headerView->setResizeMode(DataModel::NameColumn, QHeaderView::Stretch);
headerView->setResizeMode(DataModel::SelfCostColumn, QHeaderView::ResizeToContents);
setItemDelegateForColumn(DataModel::InclusiveCostColumn, d->m_costDelegate);
setItemDelegateForColumn(DataModel::NameColumn, d->m_nameDelegate);
Expand Down

0 comments on commit c107b10

Please sign in to comment.