Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move the required plugins list to before it's actually checked #16304

Merged
merged 1 commit into from
Aug 15, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
56 changes: 30 additions & 26 deletions cura/CuraApplication.py
Original file line number Diff line number Diff line change
Expand Up @@ -495,41 +495,45 @@ def __setLatestResouceVersionsForVersionUpgrade(self):
def startSplashWindowPhase(self) -> None:
"""Runs preparations that needs to be done before the starting process."""

super().startSplashWindowPhase()

if not self.getIsHeadLess():
try:
self.setWindowIcon(QIcon(Resources.getPath(Resources.Images, "cura-icon.png" if not ApplicationMetadata.IsAlternateVersion else "cura-icon_wip.png")))
except FileNotFoundError:
Logger.log("w", "Unable to find the window icon.")

self.setRequiredPlugins([
# Misc.:
"ConsoleLogger", #You want to be able to read the log if something goes wrong.
"CuraEngineBackend", #Cura is useless without this one since you can't slice.
"FileLogger", #You want to be able to read the log if something goes wrong.
"XmlMaterialProfile", #Cura crashes without this one.
"Marketplace", #This contains the interface to enable/disable plug-ins, so if you disable it you can't enable it back.
"PrepareStage", #Cura is useless without this one since you can't load models.
"PreviewStage", #This shows the list of the plugin views that are installed in Cura.
"MonitorStage", #Major part of Cura's functionality.
"LocalFileOutputDevice", #Major part of Cura's functionality.
"LocalContainerProvider", #Cura is useless without any profiles or setting definitions.
"ConsoleLogger", # You want to be able to read the log if something goes wrong.
"CuraEngineBackend", # Cura is useless without this one since you can't slice.
"FileLogger", # You want to be able to read the log if something goes wrong.
"XmlMaterialProfile", # Cura crashes without this one.
"Marketplace",
# This contains the interface to enable/disable plug-ins, so if you disable it you can't enable it back.
"PrepareStage", # Cura is useless without this one since you can't load models.
"PreviewStage", # This shows the list of the plugin views that are installed in Cura.
"MonitorStage", # Major part of Cura's functionality.
"LocalFileOutputDevice", # Major part of Cura's functionality.
"LocalContainerProvider", # Cura is useless without any profiles or setting definitions.

# Views:
"SimpleView", #Dependency of SolidView.
"SolidView", #Displays models. Cura is useless without it.
"SimpleView", # Dependency of SolidView.
"SolidView", # Displays models. Cura is useless without it.

# Readers & Writers:
"GCodeWriter", #Cura is useless if it can't write its output.
"STLReader", #Most common model format, so disabling this makes Cura 90% useless.
"3MFWriter", #Required for writing project files.
"GCodeWriter", # Cura is useless if it can't write its output.
"STLReader", # Most common model format, so disabling this makes Cura 90% useless.
"3MFWriter", # Required for writing project files.

# Tools:
"CameraTool", #Needed to see the scene. Cura is useless without it.
"SelectionTool", #Dependency of the rest of the tools.
"TranslateTool", #You'll need this for almost every print.
"CameraTool", # Needed to see the scene. Cura is useless without it.
"SelectionTool", # Dependency of the rest of the tools.
"TranslateTool", # You'll need this for almost every print.
])
# Plugins need to be set here, since in the super the check is done if they are actually loaded.

super().startSplashWindowPhase()

if not self.getIsHeadLess():
try:
self.setWindowIcon(QIcon(Resources.getPath(Resources.Images, "cura-icon.png" if not ApplicationMetadata.IsAlternateVersion else "cura-icon_wip.png")))
except FileNotFoundError:
Logger.log("w", "Unable to find the window icon.")


self._i18n_catalog = i18nCatalog("cura")

self._update_platform_activity_timer = QTimer()
Expand Down
Loading