fix focus issue and activate the surface once dropped on a workspace
commitc9164f65085c5dee92e249b6ff8acc5efda29ba2
authorMichael Zanetti <michael.zanetti@canonical.com>
dateMon 27 Mar 2017, 14:57 (10 years ago)
parentacb5d8b
qml/Stage/Spread/Workspaces.qml+2−1
@@ -70,9 +70,10 @@ Item {
7070 WorkspaceManager.moveSurfaceToWorkspace(surface, workspace);
7171 drop.accept(Qt.MoveAction)
7272 if (listView.hoveredHalf == "right") {
73− workspace.activate();
7473 root.closeSpread();
74+ workspace.activate();
7575 }
76+ surface.activate();
7677 listView.hoveredWorkspaceIndex = -1
7778 }
7879 }
qml/Stage/Stage.qml+2
@@ -230,6 +230,7 @@ FocusScope {
230230 shortcut: Qt.AltModifier|Qt.ControlModifier|Qt.Key_Left
231231 active: !workspaceSwitcher.active
232232 onTriggered: {
233+ root.focus = true;
233234 workspaceSwitcher.showLeft()
234235 }
235236 }
@@ -238,6 +239,7 @@ FocusScope {
238239 shortcut: Qt.AltModifier|Qt.ControlModifier|Qt.Key_Right
239240 active: !workspaceSwitcher.active
240241 onTriggered: {
242+ root.focus = true;
241243 workspaceSwitcher.showRight()
242244 }
243245 }
qml/Stage/WorkspaceSwitcher.qml+1
@@ -114,6 +114,7 @@ UbuntuShape {
114114 d.ctrlPressed = false;
115115 break;
116116 }
117+
117118 if (!d.altPressed && !d.ctrlPressed) {
118119 print("starting hidetimer")
119120 d.active = false;