diff options
| author | Frank Reininghaus <[email protected]> | 2010-10-05 17:56:07 +0000 |
|---|---|---|
| committer | Frank Reininghaus <[email protected]> | 2010-10-05 17:56:07 +0000 |
| commit | 2297cbee2ecc9e882d02125e4f38f3b557c83443 (patch) | |
| tree | d57084fa1aa43eb60dcabcd113ef4c8d8f31032e /src/views/dolphindetailsview.cpp | |
| parent | 7437798a875955035b8b2a5e345a3746dadb0f2d (diff) | |
Prevent that icons overlap in Details View when zooming.
The problem was that a maximum size was assigned to KFileItemDelegate
for displaying items without considering that icon zooming may change
the item height.
CCBUG: 234600
svn path=/trunk/KDE/kdebase/apps/; revision=1182797
Diffstat (limited to 'src/views/dolphindetailsview.cpp')
| -rw-r--r-- | src/views/dolphindetailsview.cpp | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/views/dolphindetailsview.cpp b/src/views/dolphindetailsview.cpp index d14186383..04ce06f6d 100644 --- a/src/views/dolphindetailsview.cpp +++ b/src/views/dolphindetailsview.cpp @@ -1070,7 +1070,19 @@ void DolphinDetailsView::updateDecorationSize(bool showPreview) setIconSize(QSize(iconSize, iconSize)); m_decorationSize = QSize(iconSize, iconSize); + if (m_extensionsFactory) { + // The old maximumSize used by KFileItemDelegate is not valid any more after the icon size change. + // It must be discarded before doItemsLayout() is called (see bug 234600). + m_extensionsFactory->fileItemDelegate()->setMaximumSize(QSize()); + } + doItemsLayout(); + + // Calculate the new maximumSize for KFileItemDelegate after the icon size change. + QModelIndex current = currentIndex(); + if (current.isValid()) { + adjustMaximumSizeForEditing(current); + } } KFileItemDelegate::Information DolphinDetailsView::infoForColumn(int columnIndex) const |
