move panels even on vertically arranged monitors up into negative space

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=758160
This commit is contained in:
Aaron J. Seigo 2008-01-07 02:15:29 +00:00
parent da34471e13
commit ea793d2259

View File

@ -674,8 +674,10 @@ void Containment::setScreen(int screen)
//kDebug() << "setting geometry to" << desktop->screenGeometry(screen) << r << geometry();
} else if (containmentType() == PanelContainment) {
QRect r = desktop->screenGeometry(screen);
//kDebug() << "we are a panel on" << r << ", let's move ourselves to a negative coordinate system" << -r.height() - INTER_CONTAINMENT_MARGIN;
int vertOffset = r.height() + INTER_CONTAINMENT_MARGIN;
//kDebug() << "we are a panel on" << r << ", let's move ourselves to a negative coordinate system" << -(r.x() * 2) - r.height() - INTER_CONTAINMENT_MARGIN;
// panels are moved into negative coords; we double the x() so that each screen get's
// it's own area for panels
int vertOffset = (r.x() * 2) + r.height() + INTER_CONTAINMENT_MARGIN;
translate(0, -vertOffset);
}
}