From 8d89983eebb5ea9af0157501b7a18c11816db379 Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Sun, 10 May 2020 12:53:27 -0700 Subject: [PATCH] Parent ScrollBars to their Flingables, not the StackView This ensures they disappear when navigating to a new page --- app/gui/AppView.qml | 15 +-------------- app/gui/PcView.qml | 9 +-------- app/gui/SettingsView.qml | 6 +----- 3 files changed, 3 insertions(+), 27 deletions(-) diff --git a/app/gui/AppView.qml b/app/gui/AppView.qml index 8ee4177a..fd34fe1d 100644 --- a/app/gui/AppView.qml +++ b/app/gui/AppView.qml @@ -263,18 +263,5 @@ CenteredGridView { onAccepted: quitApp() } - ScrollBar.vertical: ScrollBar { - // Manually hide the scrollbar to prevent it from being drawn on top - // of the StreamSegue during the transition. It can sometimes get stuck - // there since we're not consistently pumping the event loop while - // starting the stream. - visible: activated - - parent: appGrid.parent - anchors { - top: parent.top - right: parent.right - bottom: parent.bottom - } - } + ScrollBar.vertical: ScrollBar {} } diff --git a/app/gui/PcView.qml b/app/gui/PcView.qml index 7931e6ba..e653ddce 100644 --- a/app/gui/PcView.qml +++ b/app/gui/PcView.qml @@ -317,12 +317,5 @@ CenteredGridView { } } - ScrollBar.vertical: ScrollBar { - parent: pcGrid.parent - anchors { - top: parent.top - right: parent.right - bottom: parent.bottom - } - } + ScrollBar.vertical: ScrollBar {} } diff --git a/app/gui/SettingsView.qml b/app/gui/SettingsView.qml index 1c5bc131..05b63b41 100644 --- a/app/gui/SettingsView.qml +++ b/app/gui/SettingsView.qml @@ -16,12 +16,8 @@ Flickable { contentHeight: settingsColumn1.height > settingsColumn2.height ? settingsColumn1.height : settingsColumn2.height ScrollBar.vertical: ScrollBar { - parent: settingsPage.parent anchors { - top: settingsPage.top - left: settingsPage.right - bottom: settingsPage.bottom - + left: parent.right leftMargin: -10 } }