From 4e0b9d7b78884b9d022c56aa299d0c7ce22dafc9 Mon Sep 17 00:00:00 2001 From: Lipu Fei Date: Tue, 9 Jul 2019 13:01:54 +0200 Subject: [PATCH] Fix typing CURA-6597 --- cura/Machines/Models/IntentModel.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/cura/Machines/Models/IntentModel.py b/cura/Machines/Models/IntentModel.py index 87bcd08277..275087689b 100644 --- a/cura/Machines/Models/IntentModel.py +++ b/cura/Machines/Models/IntentModel.py @@ -1,15 +1,17 @@ # Copyright (c) 2019 Ultimaker B.V. # Cura is released under the terms of the LGPLv3 or higher. -from typing import Optional -from PyQt5.QtCore import QObject -from UM.Qt.ListModel import ListModel -from PyQt5.QtCore import Qt, pyqtProperty, pyqtSignal +from typing import Optional, List, Dict, Any +from PyQt5.QtCore import Qt, QObject, pyqtProperty, pyqtSignal + +from UM.Qt.ListModel import ListModel from UM.Settings.ContainerRegistry import ContainerRegistry + from cura.Settings.IntentManager import IntentManager import cura.CuraApplication + class IntentModel(ListModel): NameRole = Qt.UserRole + 1 QualityTypeRole = Qt.UserRole + 2 @@ -44,7 +46,7 @@ class IntentModel(ListModel): self._update() def _update(self) -> None: - new_items = [] + new_items = [] # type: List[Dict[str, Any]] application = cura.CuraApplication.CuraApplication.getInstance() quality_manager = application.getQualityManager() global_stack = application.getGlobalContainerStack()