SVN_SILENT: why bother with a coding style.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=711898
This commit is contained in:
parent
465b1d0072
commit
926d039802
@ -120,10 +120,11 @@ void Widget::setCachePaintMode(CachePaintMode mode, const QSize &size)
|
||||
d->cacheKey.clear();
|
||||
} else {
|
||||
d->cacheKey = QString("%1").arg(long(this));
|
||||
if (mode == ItemCoordinateCacheMode)
|
||||
if (mode == ItemCoordinateCacheMode) {
|
||||
d->cacheSize = size.isNull() ? boundingRect().size().toSize() : size;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Widget::CachePaintMode Widget::cachePaintMode() const
|
||||
{
|
||||
@ -132,8 +133,9 @@ Widget::CachePaintMode Widget::cachePaintMode() const
|
||||
|
||||
void Widget::update(const QRectF &rect)
|
||||
{
|
||||
if (d->cachePaintMode != NoCacheMode)
|
||||
if (d->cachePaintMode != NoCacheMode) {
|
||||
d->cacheInvalidated |= rect.isNull() ? boundingRect() : rect;
|
||||
}
|
||||
QGraphicsItem::update(rect);
|
||||
}
|
||||
|
||||
@ -207,12 +209,12 @@ void Widget::setGeometry(const QRectF& geometry)
|
||||
|
||||
d->size = QSizeF(width, height);
|
||||
|
||||
if ( layout() )
|
||||
if (layout()) {
|
||||
layout()->setGeometry(boundingRect());
|
||||
}
|
||||
}
|
||||
|
||||
setPos(geometry.topLeft() - boundingRect().topLeft());
|
||||
|
||||
update();
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user