Просмотр исходного кода

Remove unnecessary import and declaration of i18n in plugins

fieldOfView 6 лет назад
Родитель
Сommit
9ac744b9ba

+ 1 - 1
plugins/3MFWriter/__init__.py

@@ -12,7 +12,7 @@ from . import ThreeMFWorkspaceWriter
 from UM.i18n import i18nCatalog
 from UM.i18n import i18nCatalog
 from UM.Platform import Platform
 from UM.Platform import Platform
 
 
-i18n_catalog = i18nCatalog("uranium")
+i18n_catalog = i18nCatalog("cura")
 
 
 def getMetaData():
 def getMetaData():
     workspace_extension = "3mf"
     workspace_extension = "3mf"

+ 0 - 2
plugins/ChangeLogPlugin/__init__.py

@@ -3,8 +3,6 @@
 
 
 from . import ChangeLog
 from . import ChangeLog
 
 
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
 
 
 def getMetaData():
 def getMetaData():
     return {}
     return {}

+ 0 - 4
plugins/FirmwareUpdateChecker/__init__.py

@@ -1,12 +1,8 @@
 # Copyright (c) 2017 Ultimaker B.V.
 # Copyright (c) 2017 Ultimaker B.V.
 # Cura is released under the terms of the LGPLv3 or higher.
 # Cura is released under the terms of the LGPLv3 or higher.
 
 
-from UM.i18n import i18nCatalog
-
 from . import FirmwareUpdateChecker
 from . import FirmwareUpdateChecker
 
 
-i18n_catalog = i18nCatalog("cura")
-
 
 
 def getMetaData():
 def getMetaData():
     return {}
     return {}

+ 0 - 2
plugins/MachineSettingsAction/__init__.py

@@ -3,8 +3,6 @@
 
 
 from . import MachineSettingsAction
 from . import MachineSettingsAction
 
 
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
 
 
 def getMetaData():
 def getMetaData():
     return {}
     return {}

+ 1 - 4
plugins/ModelChecker/__init__.py

@@ -1,11 +1,8 @@
 # Copyright (c) 2018 Ultimaker B.V.
 # Copyright (c) 2018 Ultimaker B.V.
-# This example is released under the terms of the AGPLv3 or higher.
+# Cura is released under the terms of the LGPLv3 or higher.
 
 
 from . import ModelChecker
 from . import ModelChecker
 
 
-from UM.i18n import i18nCatalog
-i18n_catalog = i18nCatalog("cura")
-
 
 
 def getMetaData():
 def getMetaData():
     return {}
     return {}

+ 1 - 0
plugins/MonitorStage/__init__.py

@@ -3,6 +3,7 @@
 
 
 from . import MonitorStage
 from . import MonitorStage
 
 
+
 from UM.i18n import i18nCatalog
 from UM.i18n import i18nCatalog
 i18n_catalog = i18nCatalog("cura")
 i18n_catalog = i18nCatalog("cura")
 
 

+ 3 - 3
plugins/PostProcessingPlugin/__init__.py

@@ -2,10 +2,10 @@
 # The PostProcessingPlugin is released under the terms of the AGPLv3 or higher.
 # The PostProcessingPlugin is released under the terms of the AGPLv3 or higher.
 
 
 from . import PostProcessingPlugin
 from . import PostProcessingPlugin
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
+
+
 def getMetaData():
 def getMetaData():
     return {}
     return {}
-        
+
 def register(app):
 def register(app):
     return {"extension": PostProcessingPlugin.PostProcessingPlugin()}
     return {"extension": PostProcessingPlugin.PostProcessingPlugin()}

+ 2 - 4
plugins/RemovableDriveOutputDevice/__init__.py

@@ -3,12 +3,10 @@
 
 
 from UM.Platform import Platform
 from UM.Platform import Platform
 from UM.Logger import Logger
 from UM.Logger import Logger
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
+
 
 
 def getMetaData():
 def getMetaData():
-    return {
-    }
+    return {}
 
 
 def register(app):
 def register(app):
     if Platform.isWindows():
     if Platform.isWindows():

+ 3 - 4
plugins/SliceInfoPlugin/__init__.py

@@ -1,12 +1,11 @@
 # Copyright (c) 2015 Ultimaker B.V.
 # Copyright (c) 2015 Ultimaker B.V.
 # Cura is released under the terms of the LGPLv3 or higher.
 # Cura is released under the terms of the LGPLv3 or higher.
+
 from . import SliceInfo
 from . import SliceInfo
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
+
 
 
 def getMetaData():
 def getMetaData():
-    return {
-    }
+    return {}
 
 
 def register(app):
 def register(app):
     return { "extension": SliceInfo.SliceInfo()}
     return { "extension": SliceInfo.SliceInfo()}

+ 0 - 3
plugins/UM3NetworkPrinting/__init__.py

@@ -2,9 +2,6 @@
 # Cura is released under the terms of the LGPLv3 or higher.
 # Cura is released under the terms of the LGPLv3 or higher.
 
 
 from .src import DiscoverUM3Action
 from .src import DiscoverUM3Action
-from UM.i18n import i18nCatalog
-catalog = i18nCatalog("cura")
-
 from .src import UM3OutputDevicePlugin
 from .src import UM3OutputDevicePlugin
 
 
 def getMetaData():
 def getMetaData():

Некоторые файлы не были показаны из-за большого количества измененных файлов