mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-08-08 22:35:03 -06:00
Fix Qt warnings
resolve binding loo in `SyncState` move `updateCostPerMeter` function to root of `MaterialView` such that it is available of all sub components Cura 8687
This commit is contained in:
parent
7b8e73ae34
commit
f957cc289e
2 changed files with 8 additions and 8 deletions
|
@ -420,12 +420,6 @@ Item
|
|||
|
||||
Item { width: parent.width; height: UM.Theme.getSize("default_margin").height }
|
||||
}
|
||||
|
||||
function updateCostPerMeter()
|
||||
{
|
||||
base.spoolLength = calculateSpoolLength(diameterSpinBox.value, densitySpinBox.value, spoolWeightSpinBox.value);
|
||||
base.costPerMeter = calculateCostPerMeter(spoolCostSpinBox.value);
|
||||
}
|
||||
}
|
||||
|
||||
ListView
|
||||
|
@ -518,6 +512,12 @@ Item
|
|||
}
|
||||
}
|
||||
|
||||
function updateCostPerMeter()
|
||||
{
|
||||
base.spoolLength = calculateSpoolLength(diameterSpinBox.value, densitySpinBox.value, spoolWeightSpinBox.value);
|
||||
base.costPerMeter = calculateCostPerMeter(spoolCostSpinBox.value);
|
||||
}
|
||||
|
||||
function calculateSpoolLength(diameter, density, spoolWeight)
|
||||
{
|
||||
if(!diameter)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue