From d59910a8f298b13cc90e436a6f6efa325d863180 Mon Sep 17 00:00:00 2001 From: Joseph Donofry Date: Mon, 1 Feb 2021 18:42:18 -0500 Subject: [PATCH] Remove redundant import and fix visible warning --- resources/qml/PrivacyScreen.qml | 10 ++++++---- resources/qml/TimelineView.qml | 1 - 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/resources/qml/PrivacyScreen.qml b/resources/qml/PrivacyScreen.qml index 45ae5cb5..14a175f9 100644 --- a/resources/qml/PrivacyScreen.qml +++ b/resources/qml/PrivacyScreen.qml @@ -29,10 +29,12 @@ Item { interval: screenTimeout * 1000 running: true onTriggered: { - timelineRoot.grabToImage(function(result) { - screenSaver.state = "Visible"; - imageSource = result.url; - }, Qt.size(width, height)); + if (MainWindow.visible) { + timelineRoot.grabToImage(function(result) { + screenSaver.state = "Visible"; + imageSource = result.url; + }, Qt.size(width, height)); + } } } diff --git a/resources/qml/TimelineView.qml b/resources/qml/TimelineView.qml index 35d09d5a..379b19fb 100644 --- a/resources/qml/TimelineView.qml +++ b/resources/qml/TimelineView.qml @@ -1,4 +1,3 @@ -import "." import "./delegates" import "./device-verification" import "./emoji"