geometry() isn't up to date at the time that an ItemPositionHasChanged
notification is received, so don't use it in calculating the correct position. Also some other small WoC cleanups. BUG: 161969 svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=812493
This commit is contained in:
parent
bfc47e7c3a
commit
f478ae1ca4
@ -344,16 +344,12 @@ QGraphicsView *Applet::view() const
|
||||
|
||||
QRectF Applet::mapFromView(const QGraphicsView *view, const QRect &rect) const
|
||||
{
|
||||
// TODO: Confirm that adjusted() is needed and is not covering for some
|
||||
// issue elsewhere
|
||||
return mapFromScene(view->mapToScene(rect)).boundingRect().adjusted(0, 0, 1, 1);
|
||||
return mapFromScene(view->mapToScene(rect)).boundingRect();
|
||||
}
|
||||
|
||||
QRect Applet::mapToView(const QGraphicsView *view, const QRectF &rect) const
|
||||
{
|
||||
// TODO: Confirm that adjusted() is needed and is not covering for some
|
||||
// issue elsewhere
|
||||
return view->mapFromScene(mapToScene(rect)).boundingRect().adjusted(0, 0, -1, -1);
|
||||
return view->mapFromScene(mapToScene(rect)).boundingRect();
|
||||
}
|
||||
|
||||
QPoint Applet::popupPosition(const QSize &s) const
|
||||
|
Loading…
Reference in New Issue
Block a user