mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-20 13:17:51 -06:00
Use ListModel.count instead of rowCount
The .count property properly updates when the model is changed. Contributes to issue CURA-5876.
This commit is contained in:
parent
db05d7853a
commit
f3af5a72ad
14 changed files with 49 additions and 36 deletions
|
@ -170,7 +170,7 @@ UM.Dialog
|
|||
if (machineList.model.getItem(machineList.currentIndex).section != section)
|
||||
{
|
||||
// Find the first machine from this section
|
||||
for(var i = 0; i < machineList.model.rowCount(); i++)
|
||||
for(var i = 0; i < machineList.model.count; i++)
|
||||
{
|
||||
var item = machineList.model.getItem(i);
|
||||
if (item.section == section)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue