aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Lübking <thomas.luebking@gmail.com>2012-05-26 20:12:58 (GMT)
committerThomas Lübking <thomas.luebking@gmail.com>2012-05-27 19:43:09 (GMT)
commit0910f10fbdc0e3a5165011055be35a91836b8d29 (patch)
tree415f419c2e1d72568e6f3074b478472cc9b0212b
parentb6081d623550aa2d1145d3b3b5ceafbc119e12eb (diff)
move reinitCascading to setNumberOfDesktops because it updates an internal list that is trusted to be of (at least) desktopCount_ size
hand backport of b94ccd516710f8b6a951bbac969e1627f466a6cb BUG: 174118 FIXED-IN: 4.8.4 REVIEW: 105063
-rw-r--r--kwin/workspace.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/kwin/workspace.cpp b/kwin/workspace.cpp
index b4fd277..52072a1 100644
--- a/kwin/workspace.cpp
+++ b/kwin/workspace.cpp
@@ -400,6 +400,9 @@ void Workspace::init()
QX11Info info;
rootInfo = new RootInfo(this, display(), supportWindow->winId(), "KWin", protocols, 5, info.screen());
+ // Now we know how many desktops we'll have, thus we initialize the positioning object
+ initPositioning = new Placement(this);
+
loadDesktopSettings();
updateDesktopLayout();
// Extra NETRootInfo instance in Client mode is needed to get the values of the properties
@@ -416,9 +419,6 @@ void Workspace::init()
allActivities_ = activityController_.listActivities();
updateCurrentActivity(activityController_.currentActivity());
- // Now we know how many desktops we'll have, thus we initialize the positioning object
- initPositioning = new Placement(this);
-
reconfigureTimer.setSingleShot(true);
updateToolWindowsTimer.setSingleShot(true);
@@ -965,7 +965,6 @@ void Workspace::slotReconfigure()
unsigned long changed = options->updateSettings();
emit configChanged();
- initPositioning->reinitCascading(0);
discardPopup();
forEachClient(CheckIgnoreFocusStealingProcedure());
updateToolWindows(true);
@@ -1591,6 +1590,7 @@ void Workspace::setNumberOfDesktops(int n)
return;
int old_number_of_desktops = numberOfDesktops();
desktopCount_ = n;
+ initPositioning->reinitCascading(0);
updateDesktopLayout(); // Make sure the layout is still valid
if (currentDesktop() > n)