From 248c1deda488726acfc81b98a3e2e1f3b7bb5fbc Mon Sep 17 00:00:00 2001 From: kateleet Date: Tue, 21 Dec 2021 05:32:32 +0800 Subject: [PATCH] fix(qml): a warning --- qml/FolderPage.qml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/qml/FolderPage.qml b/qml/FolderPage.qml index fb3ec22..42f02a4 100644 --- a/qml/FolderPage.qml +++ b/qml/FolderPage.qml @@ -39,6 +39,9 @@ Item { signal requestPathEditor() onCurrentUrlChanged: { + if (!_viewLoader.item) + return + _viewLoader.item.reset() _viewLoader.item.forceActiveFocus() } @@ -207,6 +210,7 @@ Item { id: _viewLoader Layout.fillWidth: true Layout.fillHeight: true + asynchronous: true sourceComponent: switch (settings.viewMethod) { case 0: return _listViewComponent case 1: return _gridViewComponent