From 8a36f1e0744c6fbd85efd76ace60315bcc850056 Mon Sep 17 00:00:00 2001 From: Ghostkeeper Date: Fri, 23 Mar 2018 14:23:10 +0100 Subject: [PATCH] Make opacity depend on enabled Simplifies the code a bit. Contributes to issue CURA-5128. --- plugins/PluginBrowser/PluginEntry.qml | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/plugins/PluginBrowser/PluginEntry.qml b/plugins/PluginBrowser/PluginEntry.qml index fab8f43e07..9dbcb96e79 100644 --- a/plugins/PluginBrowser/PluginEntry.qml +++ b/plugins/PluginBrowser/PluginEntry.qml @@ -1,4 +1,4 @@ -// Copyright (c) 2017 Ultimaker B.V. +// Copyright (c) 2018 Ultimaker B.V. // PluginBrowser is released under the terms of the LGPLv3 or higher. import QtQuick 2.2 @@ -140,17 +140,7 @@ Component { return true } } - opacity: - { - if ( pluginList.activePlugin == model ) - { - return 1.0 - } - else - { - manager.isDownloading ? 0.5 : 1.0 - } - } + opacity: enabled ? 1.0 : 0.5 visible: model.external && ((model.status !== "installed") || model.can_upgrade) style: ButtonStyle { background: Rectangle {