Optimisation: Don't work out position based on visualParent if there isn't one

This commit is contained in:
David Edmundson 2014-01-29 16:54:56 +01:00
parent a805af6e7d
commit c9c79e7a42

View File

@ -378,12 +378,11 @@ void DialogProxy::syncToMainItemSize()
QSize(m_frameSvgItem->margins()->left() + m_frameSvgItem->margins()->right(),
m_frameSvgItem->margins()->top() + m_frameSvgItem->margins()->bottom());
const QRect geom(popupPosition(visualParent(), s, Qt::AlignCenter), s);
if (geom == geometry()) {
return;
}
if (visualParent()) {
const QRect geom(popupPosition(visualParent(), s, Qt::AlignCenter), s);
if (geom == geometry()) {
return;
}
adjustGeometry(geom);
} else {
resize(s);