Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/Ultimaker/Cura.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCasper Lamboo <c.lamboo@ultimaker.com>2022-02-24 15:39:49 +0300
committerGitHub <noreply@github.com>2022-02-24 15:39:49 +0300
commit9fa6698da3fad625c192da4f7094a87ac2615595 (patch)
treebb35f19dfd395585f1a8533ea4d1d5418bd6f630 /plugins/Marketplace/resources
parent08466d426de11434ec6a45169392c00b60a2ddaa (diff)
parent095b8dc5dd00e1fc8300e9f530b6a44018ee7277 (diff)
Merge pull request #11536 from Ultimaker/CURA-8834_marketplace_packages_install_status_in_list
Show install, uninstall & disable buttons in packages list
Diffstat (limited to 'plugins/Marketplace/resources')
-rw-r--r--plugins/Marketplace/resources/qml/ManagedPackages.qml5
-rw-r--r--plugins/Marketplace/resources/qml/Materials.qml3
-rw-r--r--plugins/Marketplace/resources/qml/PackageCard.qml4
-rw-r--r--plugins/Marketplace/resources/qml/PackageCardHeader.qml11
-rw-r--r--plugins/Marketplace/resources/qml/PackagePage.qml4
-rw-r--r--plugins/Marketplace/resources/qml/Packages.qml9
-rw-r--r--plugins/Marketplace/resources/qml/Plugins.qml3
7 files changed, 27 insertions, 12 deletions
diff --git a/plugins/Marketplace/resources/qml/ManagedPackages.qml b/plugins/Marketplace/resources/qml/ManagedPackages.qml
index 3eb77d8485..9358a04f07 100644
--- a/plugins/Marketplace/resources/qml/ManagedPackages.qml
+++ b/plugins/Marketplace/resources/qml/ManagedPackages.qml
@@ -19,7 +19,8 @@ Packages
bannerVisible = false;
}
searchInBrowserUrl: "https://marketplace.ultimaker.com/app/cura/plugins?utm_source=cura&utm_medium=software&utm_campaign=marketplace-search-plugins-browser"
- packagesManageableInListView: true
-
+ showUpdateButton: true
+ showInstallButton: true
+ showDisableButton: true
model: manager.LocalPackageList
}
diff --git a/plugins/Marketplace/resources/qml/Materials.qml b/plugins/Marketplace/resources/qml/Materials.qml
index ddac8b0bbe..c10a937d67 100644
--- a/plugins/Marketplace/resources/qml/Materials.qml
+++ b/plugins/Marketplace/resources/qml/Materials.qml
@@ -16,7 +16,8 @@ Packages
bannerVisible = false;
}
searchInBrowserUrl: "https://marketplace.ultimaker.com/app/cura/materials?utm_source=cura&utm_medium=software&utm_campaign=marketplace-search-materials-browser"
- packagesManageableInListView: false
+ showUpdateButton: true
+ showInstallButton: true
model: manager.MaterialPackageList
}
diff --git a/plugins/Marketplace/resources/qml/PackageCard.qml b/plugins/Marketplace/resources/qml/PackageCard.qml
index 9a5f9beab6..7442c63aa6 100644
--- a/plugins/Marketplace/resources/qml/PackageCard.qml
+++ b/plugins/Marketplace/resources/qml/PackageCard.qml
@@ -11,7 +11,9 @@ import Cura 1.6 as Cura
Rectangle
{
property alias packageData: packageCardHeader.packageData
- property alias manageableInListView: packageCardHeader.showManageButtons
+ property alias showUpdateButton: packageCardHeader.showUpdateButton
+ property alias showDisableButton: packageCardHeader.showDisableButton
+ property alias showInstallButton: packageCardHeader.showInstallButton
height: childrenRect.height
color: UM.Theme.getColor("main_background")
diff --git a/plugins/Marketplace/resources/qml/PackageCardHeader.qml b/plugins/Marketplace/resources/qml/PackageCardHeader.qml
index 9e3e673ea2..013704793f 100644
--- a/plugins/Marketplace/resources/qml/PackageCardHeader.qml
+++ b/plugins/Marketplace/resources/qml/PackageCardHeader.qml
@@ -15,7 +15,10 @@ Item
default property alias contents: contentItem.children
property var packageData
- property bool showManageButtons: false
+ property bool showDisableButton: false
+ property bool showInstallButton: false
+ property bool showUpdateButton: false
+
width: parent.width
height: UM.Theme.getSize("card").height
@@ -170,7 +173,7 @@ Item
ManageButton
{
id: enableManageButton
- visible: showManageButtons && packageData.isInstalled && !packageData.isToBeInstalled && packageData.packageType != "material"
+ visible: showDisableButton && packageData.isInstalled && !packageData.isToBeInstalled && packageData.packageType != "material"
enabled: !packageData.busy
button_style: !packageData.isActive
@@ -184,7 +187,7 @@ Item
ManageButton
{
id: installManageButton
- visible: showManageButtons && (packageData.canDowngrade || !packageData.isBundled)
+ visible: showInstallButton && (packageData.canDowngrade || !packageData.isBundled)
enabled: !packageData.busy
busy: packageData.busy
button_style: !(packageData.isInstalled || packageData.isToBeInstalled)
@@ -214,7 +217,7 @@ Item
ManageButton
{
id: updateManageButton
- visible: showManageButtons && packageData.canUpdate
+ visible: showUpdateButton && packageData.canUpdate
enabled: !packageData.busy
busy: packageData.busy
Layout.alignment: Qt.AlignTop
diff --git a/plugins/Marketplace/resources/qml/PackagePage.qml b/plugins/Marketplace/resources/qml/PackagePage.qml
index 4384d2843f..e590ee6091 100644
--- a/plugins/Marketplace/resources/qml/PackagePage.qml
+++ b/plugins/Marketplace/resources/qml/PackagePage.qml
@@ -31,7 +31,9 @@ Rectangle
PackageCardHeader
{
id: packageCardHeader
- showManageButtons: true
+ showUpdateButton: true
+ showInstallButton: true
+ showDisableButton: true
anchors.fill: parent
diff --git a/plugins/Marketplace/resources/qml/Packages.qml b/plugins/Marketplace/resources/qml/Packages.qml
index 5cd52e5628..56fffe036e 100644
--- a/plugins/Marketplace/resources/qml/Packages.qml
+++ b/plugins/Marketplace/resources/qml/Packages.qml
@@ -19,7 +19,10 @@ ListView
property string bannerText
property string bannerReadMoreUrl
property var onRemoveBanner
- property bool packagesManageableInListView
+
+ property bool showUpdateButton
+ property bool showDisableButton
+ property bool showInstallButton
clip: true
@@ -81,7 +84,9 @@ ListView
PackageCard
{
- manageableInListView: packages.packagesManageableInListView
+ showUpdateButton: packages.showUpdateButton
+ showDisableButton: packages.showDisableButton
+ showInstallButton: packages.showInstallButton
packageData: model.package
width: {
if (verticalScrollBar.visible)
diff --git a/plugins/Marketplace/resources/qml/Plugins.qml b/plugins/Marketplace/resources/qml/Plugins.qml
index f1a524c029..739e0c01a7 100644
--- a/plugins/Marketplace/resources/qml/Plugins.qml
+++ b/plugins/Marketplace/resources/qml/Plugins.qml
@@ -16,7 +16,8 @@ Packages
bannerVisible = false;
}
searchInBrowserUrl: "https://marketplace.ultimaker.com/app/cura/plugins?utm_source=cura&utm_medium=software&utm_campaign=marketplace-search-plugins-browser"
- packagesManageableInListView: false
+ showUpdateButton: true
+ showInstallButton: true
model: manager.PluginPackageList
}