mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-09-09 00:07:52 -06:00
Preheat now shows error color like all other input fields
This commit is contained in:
parent
78141cf330
commit
ccb3f225ff
1 changed files with 11 additions and 1 deletions
|
@ -320,7 +320,17 @@ Column
|
||||||
Rectangle //Input field for pre-heat temperature.
|
Rectangle //Input field for pre-heat temperature.
|
||||||
{
|
{
|
||||||
id: preheatTemperatureControl
|
id: preheatTemperatureControl
|
||||||
color: !enabled ? UM.Theme.getColor("setting_control_disabled") : UM.Theme.getColor("setting_validation_ok")
|
color: !enabled ? UM.Theme.getColor("setting_control_disabled") : showError ? UM.Theme.getColor("setting_validation_error") : UM.Theme.getColor("setting_validation_ok")
|
||||||
|
property var showError:
|
||||||
|
{
|
||||||
|
if(bedTemperature.properties.maximum_value != "None" && bedTemperature.properties.maximum_value < parseInt(preheatTemperatureInput.text))
|
||||||
|
{
|
||||||
|
return true;
|
||||||
|
} else
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
enabled:
|
enabled:
|
||||||
{
|
{
|
||||||
if (connectedPrinter == null)
|
if (connectedPrinter == null)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue