From e5d32716980c82d50bc3690963f303da3757eac5 Mon Sep 17 00:00:00 2001 From: Kostas Karmas Date: Mon, 3 Aug 2020 17:43:14 +0200 Subject: [PATCH] Fix mypy complaining that Application has no createQmlComponent Using CuraApplication instead fixes the problem CURA-7609 --- plugins/3MFReader/WorkspaceDialog.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugins/3MFReader/WorkspaceDialog.py b/plugins/3MFReader/WorkspaceDialog.py index 4676a557e9..7291c81e9f 100644 --- a/plugins/3MFReader/WorkspaceDialog.py +++ b/plugins/3MFReader/WorkspaceDialog.py @@ -12,6 +12,9 @@ from UM.Settings.ContainerRegistry import ContainerRegistry import os import threading import time + +from cura.CuraApplication import CuraApplication + i18n_catalog = i18nCatalog("cura") @@ -295,7 +298,7 @@ class WorkspaceDialog(QObject): three_mf_reader_path = PluginRegistry.getInstance().getPluginPath("3MFReader") if three_mf_reader_path: path = os.path.join(three_mf_reader_path, self._qml_url) - self._view = Application.getInstance().createQmlComponent(path, {"manager": self}) + self._view = CuraApplication.getInstance().createQmlComponent(path, {"manager": self}) def show(self) -> None: # Emit signal so the right thread actually shows the view.