Partially revert 8037fb76fc to fix mouse polling issues on Windows

This commit is contained in:
Cameron Gutman
2019-03-02 14:11:30 -08:00
parent 8492482e55
commit 292cc579cf
+15 -5
View File
@@ -15,6 +15,11 @@ Item {
anchors.fill: parent anchors.fill: parent
// The StackView will trigger a visibility change when
// we're pushed onto it, causing our onVisibleChanged
// routine to run, but only if we start as invisible
visible: false
function stageStarting(stage) function stageStarting(stage)
{ {
// Update the spinner text // Update the spinner text
@@ -100,7 +105,16 @@ Item {
id: gamepadKeyNav id: gamepadKeyNav
} }
StackView.onActivated: { StackView.onDeactivating: {
// Show the toolbar again when popped off the stack
toolBar.visible = true
}
// !!! Changing this to use the StackView activation callbacks
// causes our mouse polling rate to drop significantly on
// Windows for some reason !!!
onVisibleChanged: {
if (visible) {
// Hide the toolbar before we start loading // Hide the toolbar before we start loading
toolBar.visible = false toolBar.visible = false
@@ -124,10 +138,6 @@ Item {
// Run the streaming session to completion // Run the streaming session to completion
session.exec(Screen.virtualX, Screen.virtualY) session.exec(Screen.virtualX, Screen.virtualY)
} }
StackView.onDeactivating: {
// Show the toolbar again
toolBar.visible = true
} }
Row { Row {