Fix applets jumping around when they resize. Avoid calling setGeometry() on Applets in a FreeLayout that have not changed their size hint since the last update.
svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=712674
This commit is contained in:
parent
329d912f47
commit
7b607e92c9
@ -83,7 +83,9 @@ LayoutItem * FreeLayout::takeAt(int i)
|
|||||||
void FreeLayout::setGeometry(const QRectF &geometry)
|
void FreeLayout::setGeometry(const QRectF &geometry)
|
||||||
{
|
{
|
||||||
foreach (LayoutItem *child , d->children) {
|
foreach (LayoutItem *child , d->children) {
|
||||||
child->setGeometry(QRectF(child->geometry().topLeft(),child->sizeHint()));
|
if (child->geometry().size() != child->sizeHint()) {
|
||||||
|
child->setGeometry(QRectF(child->geometry().topLeft(),child->sizeHint()));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
d->geometry = geometry;
|
d->geometry = geometry;
|
||||||
}
|
}
|
||||||
|
@ -217,7 +217,7 @@ void Widget::setGeometry(const QRectF& geometry)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
setPos(geometry.topLeft() - boundingRect().topLeft());
|
setPos(geometry.topLeft());
|
||||||
update();
|
update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user