i wonder if this fixes it; can the reporters test this for me, because it wasn't being triggered here, but i can see how it could be without this patch
CCBUG:163477 svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=818638
This commit is contained in:
parent
681ddb5cdc
commit
c9fcf43c43
@ -1254,6 +1254,7 @@ void Containment::Private::positionContainment()
|
||||
QList<Containment*> containments = c->containments();
|
||||
QMutableListIterator<Containment*> it(containments);
|
||||
|
||||
bool noCollissions = true;
|
||||
while (it.hasNext()) {
|
||||
Containment *containment = it.next();
|
||||
if (containment == q ||
|
||||
@ -1264,12 +1265,12 @@ void Containment::Private::positionContainment()
|
||||
continue;
|
||||
}
|
||||
|
||||
if (q->collidesWithItem(containment)) {
|
||||
break;
|
||||
if (noCollissions && q->collidesWithItem(containment)) {
|
||||
noCollissions = false;
|
||||
}
|
||||
}
|
||||
|
||||
if (!it.hasNext()) {
|
||||
if (noCollissions) {
|
||||
// we made it all the way through the list, we have no
|
||||
// collisions
|
||||
return;
|
||||
@ -1309,8 +1310,11 @@ void Containment::Private::positionContainment()
|
||||
|
||||
while (it.hasNext()) {
|
||||
Containment *containment = it.next();
|
||||
|
||||
if (q->collidesWithItem(containment)) {
|
||||
shift = containment->boundingRect().right();
|
||||
//TODO: is it safe to remove a containment once we've
|
||||
// collided with it?
|
||||
break;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user