Several reasons:
* It's bad style, making it harder to test with mocked PluginRegistry since all sorts of objects have copies of the un-mocked object in their fields.
* It's causing errors in this case when checkIfRestartNeeded is called before show().
Fixes Sentry issue CURA-3P6.
Swapped the loading order of Marketplace extensions so SyncOrchestractor is not fetched by PluginRegistry.getInstance().getPluginObject("Marketplace") in WorkspaceDialog.
CURA-8610
This adds a new function to the API of the Marketplace plug-in.
It's not pretty, but it's going to be how it is for a while.
Done to fix a critical build issue. The 'import plugins' thing works from source but not on the build.
The checkbox was still there in the preferences page, but it didn't work at all, for two reasons:
- The preference entry didn't exist. This was causing warnings in the log (which is why I saw it).
- It wasn't checking the preference before making that API call. Could make a bunch of people pretty angry.
Was using Qt5 still, even though we're dumping that. Need a bit of a level playing field for an update to the way we handle libArcus and libSavitar.
part of CURA-7924
Should have done this from the start.
Will move other relevant scattered functions to this type.
For now it checks if the restart banner needs to show.
Taking into account that a user can toggle between enable
and disable without an actual restart. Even with multiple
plugins.
Contributes to: CURA-8587
The server is queried using the local packages_id and version to
determine if they can be updated. The Manage button state is set
accordingly. This is done in an async way to keep the UI responsive
A.t.m I'm not sure if I might need to move this logic out, since
we also need to make this query when check periodically for updates.
when the list is not shown. But that would also entail creating
the installed packages list before the Manage Packages tab is ever
created in the Marketplace.
Contributes to: CURA-8587
There is a distinction between packages which are already
installed on the local machine and packages which are
available on the remote server. Even with this difference
it is important that they are handled the same and can be
reused in the same GUI elements.
In order to reduce code duplication I created a parent object
PackageList which contains the base logic and interface for
the QML and let both RemotePackageList and LocalPackageList
inherit from this.
UX specified that the gear icon (Settings.svg) should be
separate from the tabs of material and plugins. This also
ment that the current tab item couldn't set the pageTitle
anymore. This is now defined in the Package component and
set when the loader has loaded the external QML file.
Contributes to CURA-8558
This way it's not available to the rest of Cura, especially since PackageList is not such an uncommon name. It could give name collisions. Moreover, the rest of Cura doesn't need to have a list of packages from the Marketplace, so it's better separation.
Contributes to issue CURA-8556.
This plug-in will be a complete re-write of the previous Toolbox plug-in. It's intended to solve some of the inherent architectural problems with the Toolbox.
We're calling it Marketplace now as well.
Contributes to issue CURA-8556.