if we are switching two containments in Containment::setScreen()
let's before emit a screenchanged with -1 as the new screen for both. this will make the views forget about them and they won't try to swao them again makes possible to switch containments on multimonitor or pervirtualdesktopviews=true svn path=/trunk/KDE/kdelibs/; revision=1063989
This commit is contained in:
parent
7732b62f16
commit
d16be0c15a
@ -1028,7 +1028,10 @@ void Containment::setScreen(int newScreen, int newDesktop)
|
|||||||
<< "and is" << currently->activity()
|
<< "and is" << currently->activity()
|
||||||
<< (QObject*)currently << "i'm" << (QObject*)this;
|
<< (QObject*)currently << "i'm" << (QObject*)this;
|
||||||
//kDebug() << "setScreen due to swap";
|
//kDebug() << "setScreen due to swap";
|
||||||
|
//make the view completely forget about us
|
||||||
|
emit screenChanged(d->screen, -1, this);
|
||||||
currently->setScreen(-1, newDesktop);
|
currently->setScreen(-1, newDesktop);
|
||||||
|
emit screenChanged(-1, newDesktop, currently);
|
||||||
swapScreensWith = currently;
|
swapScreensWith = currently;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1050,9 +1053,7 @@ void Containment::setScreen(int newScreen, int newDesktop)
|
|||||||
updateConstraints(Plasma::ScreenConstraint);
|
updateConstraints(Plasma::ScreenConstraint);
|
||||||
|
|
||||||
if (oldScreen != newScreen || oldDesktop != newDesktop) {
|
if (oldScreen != newScreen || oldDesktop != newDesktop) {
|
||||||
if (oldScreen != newScreen) {
|
emit screenChanged(oldScreen, newScreen, this);
|
||||||
emit screenChanged(oldScreen, newScreen, this);
|
|
||||||
}
|
|
||||||
|
|
||||||
KConfigGroup c = config();
|
KConfigGroup c = config();
|
||||||
c.writeEntry("screen", d->screen);
|
c.writeEntry("screen", d->screen);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user