diff options
| author | Peter Penz <[email protected]> | 2012-01-30 12:59:38 +0100 |
|---|---|---|
| committer | Peter Penz <[email protected]> | 2012-01-30 13:01:06 +0100 |
| commit | 832b647c537bb520244d1222a4fb6440fe7024a6 (patch) | |
| tree | 91c5331f6363eee23afce055221c52bab8cdfe38 /src/views/dolphinitemlistcontainer.cpp | |
| parent | 517743a1bf2fab754182b53ba180be4043ed2148 (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; |
