Changeset View
Changeset View
Standalone View
Standalone View
src/widgets/delegateanimationhandler.cpp
| Show First 20 Lines • Show All 47 Lines • ▼ Show 20 Line(s) | |||||
| 48 | }; | 48 | }; | ||
| 49 | 49 | | |||
| 50 | // Debug output is disabled by default, use kdebugdialog to enable it | 50 | // Debug output is disabled by default, use kdebugdialog to enable it | ||
| 51 | //static int animationDebugArea() { static int s_area = KDebug::registerArea("kio (delegateanimationhandler)", false); | 51 | //static int animationDebugArea() { static int s_area = KDebug::registerArea("kio (delegateanimationhandler)", false); | ||
| 52 | // return s_area; } | 52 | // return s_area; } | ||
| 53 | 53 | | |||
| 54 | // --------------------------------------------------------------------------- | 54 | // --------------------------------------------------------------------------- | ||
| 55 | 55 | | |||
| 56 | CachedRendering::CachedRendering(QStyle::State state, const QSize &size, QModelIndex index, qreal devicePixelRatio) | 56 | CachedRendering::CachedRendering(QStyle::State state, const QSize &size, QModelIndex index, bool columnView, qreal devicePixelRatio) | ||
| 57 | : state(state), regular(QPixmap(size*devicePixelRatio)), hover(QPixmap(size*devicePixelRatio)), valid(true), validityIndex(index) | 57 | : state(state), | ||
| 58 | regular(QPixmap(size*devicePixelRatio)), | ||||
| 59 | hover(QPixmap(size*devicePixelRatio)), | ||||
| 60 | columnView(columnView), | ||||
| 61 | valid(true), | ||||
| 62 | validityIndex(index) | ||||
| 58 | { | 63 | { | ||
| 59 | regular.setDevicePixelRatio(devicePixelRatio); | 64 | regular.setDevicePixelRatio(devicePixelRatio); | ||
| 60 | hover.setDevicePixelRatio(devicePixelRatio); | 65 | hover.setDevicePixelRatio(devicePixelRatio); | ||
| 61 | regular.fill(Qt::transparent); | 66 | regular.fill(Qt::transparent); | ||
| 62 | hover.fill(Qt::transparent); | 67 | hover.fill(Qt::transparent); | ||
| 63 | 68 | | |||
| 64 | if (index.model()) { | 69 | if (index.model()) { | ||
| 65 | connect(index.model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), | 70 | connect(index.model(), SIGNAL(dataChanged(QModelIndex,QModelIndex)), | ||
| ▲ Show 20 Lines • Show All 377 Lines • Show Last 20 Lines | |||||