when the view is not zoomed move the toolbox to avoid the panels

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=811374
This commit is contained in:
Marco Martin 2008-05-22 20:22:28 +00:00
parent 1ff027988b
commit bc1688ae41

View File

@ -1047,7 +1047,14 @@ void Containment::Private::positionToolBox()
}
}
} else {
toolBox->setPos(q->mapFromScene(QPointF(q->geometry().topRight())));
QRectF r;
QDesktopWidget *desktop = QApplication::desktop();
r = desktop->availableGeometry(screen);
if (q->view() && !q->view()->transform().isScaling()) {
toolBox->setPos(r.topRight());
} else {
toolBox->setPos(q->mapFromScene(QPointF(q->geometry().topRight())));
}
}
}