mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-23 06:33:55 -06:00
WIP: Make CuraPackageManager aggregate PluginRegistry data
CURA-4644
This commit is contained in:
parent
f510603cb5
commit
0f966115e6
5 changed files with 83 additions and 53 deletions
|
@ -322,31 +322,6 @@ UM.MainWindow
|
|||
{
|
||||
if (drop.urls.length > 0)
|
||||
{
|
||||
// As the drop area also supports plugins, first check if it's a plugin that was dropped.
|
||||
if (drop.urls.length == 1)
|
||||
{
|
||||
if (PluginRegistry.isPluginFile(drop.urls[0]))
|
||||
{
|
||||
// Try to install plugin & close.
|
||||
var result = PluginRegistry.installPlugin(drop.urls[0]);
|
||||
pluginInstallDialog.text = result.message;
|
||||
if (result.status == "ok")
|
||||
{
|
||||
pluginInstallDialog.icon = StandardIcon.Information;
|
||||
}
|
||||
else if (result.status == "duplicate")
|
||||
{
|
||||
pluginInstallDialog.icon = StandardIcon.Warning;
|
||||
}
|
||||
else
|
||||
{
|
||||
pluginInstallDialog.icon = StandardIcon.Critical;
|
||||
}
|
||||
pluginInstallDialog.open();
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
openDialog.handleOpenFileUrls(drop.urls);
|
||||
}
|
||||
}
|
||||
|
@ -813,14 +788,6 @@ UM.MainWindow
|
|||
}
|
||||
}
|
||||
|
||||
MessageDialog
|
||||
{
|
||||
id: pluginInstallDialog
|
||||
title: catalog.i18nc("@window:title", "Install Plugin");
|
||||
standardButtons: StandardButton.Ok
|
||||
modality: Qt.ApplicationModal
|
||||
}
|
||||
|
||||
MessageDialog {
|
||||
id: infoMultipleFilesWithGcodeDialog
|
||||
title: catalog.i18nc("@title:window", "Open File(s)")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue