Default Desktop and layout
Petri Damstén
petri.damsten at gmail.com
Mon Aug 25 10:28:09 CEST 2008
Hi,
Layout in default desktop does not work on second screen. In
DefaultDesktop::refreshWorkingArea it calls setWorkingArea with screen
geometry which sets workingStart to 1280,0 (on my second screen). Using this
workingStart added applets are then moved outside of my screen (which is
1280x1024). I guess it should be something like this:
Index: containments/desktop/desktop.cpp
===================================================================
--- containments/desktop/desktop.cpp (revision 852024)
+++ containments/desktop/desktop.cpp (working copy)
@@ -279,11 +279,15 @@
void DefaultDesktop::refreshWorkingArea()
{
- QRectF workingGeom = geometry();
+ QRectF workingGeom;
if (screen() != -1) {
// we are associated with a screen, make sure not to overlap panels
QDesktopWidget *desktop = qApp->desktop();
workingGeom = desktop->availableGeometry(screen());
+ // From screen coordinates to containment coordinates
+ workingGeom.translate(-desktop->screenGeometry(screen()).topLeft());
+ } else {
+ workingGeom = geometry();
}
m_layout->setWorkingArea(workingGeom);
}
Petri
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/plasma-devel/attachments/20080825/0f183932/attachment.sig
More information about the Plasma-devel
mailing list