diff options
| author | Peter Penz <[email protected]> | 2012-01-30 12:59:38 +0100 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2012-01-30 13:01:13 +0100 |
| commit | 6c39b4622f6d9920e5f8905a1d26da4a2b11b234 (patch) | |
| tree | c1c63df1e9d3dd047022b163046960b05443a024 /src/views/dolphinitemlistcontainer.cpp | |
| parent | 1d7088b1ada3de716ff591c22d400198450208d4 (diff) | |
Further animation optimizations
- Assure a proper minimim width in the compact mode.
- Don't calculate the old position of hidden items to animate the
moving. Just show them directly.
Diffstat (limited to 'src/views/dolphinitemlistcontainer.cpp')
| -rw-r--r-- | src/views/dolphinitemlistcontainer.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/views/dolphinitemlistcontainer.cpp b/src/views/dolphinitemlistcontainer.cpp index 38adfde64..7c32f982a 100644 --- a/src/views/dolphinitemlistcontainer.cpp +++ b/src/views/dolphinitemlistcontainer.cpp @@ -209,7 +209,7 @@ void DolphinItemListContainer::updateGridSize() switch (itemLayout()) { case KFileItemListView::IconsLayout: { const int minItemWidth = 64; - itemWidth = minItemWidth + IconsModeSettings::textWidthIndex() * 64; // TODO: + itemWidth = minItemWidth + IconsModeSettings::textWidthIndex() * 64; if (itemWidth < iconSize + innerMargin * 2) { itemWidth = iconSize + innerMargin * 2; } @@ -217,7 +217,7 @@ void DolphinItemListContainer::updateGridSize() break; } case KFileItemListView::CompactLayout: { - itemWidth = innerMargin * 2; + itemWidth = innerMargin * 4 + iconSize + styleOption.fontMetrics.height() * 5; const int textLinesCount = m_fileItemListView->visibleRoles().count(); itemHeight = innerMargin * 2 + qMax(iconSize, textLinesCount * styleOption.fontMetrics.height()); break; |
