mirror of
https://github.com/Ultimaker/Cura.git
synced 2025-07-25 15:44:04 -06:00
Don't update material menu when it's not visible
Knocks off about a second of loading
This commit is contained in:
parent
b1cd5960b8
commit
b7296dd700
1 changed files with 10 additions and 2 deletions
|
@ -2,7 +2,7 @@
|
||||||
//Cura is released under the terms of the LGPLv3 or higher.
|
//Cura is released under the terms of the LGPLv3 or higher.
|
||||||
|
|
||||||
import QtQuick 2.2
|
import QtQuick 2.2
|
||||||
import QtQuick.Controls 1.1
|
import QtQuick.Controls 1.4
|
||||||
|
|
||||||
import UM 1.2 as UM
|
import UM 1.2 as UM
|
||||||
import Cura 1.0 as Cura
|
import Cura 1.0 as Cura
|
||||||
|
@ -24,7 +24,15 @@ Menu
|
||||||
title: modelData.name
|
title: modelData.name
|
||||||
property var extruder: (base.activeMachine === null) ? null : activeMachine.extruderList[model.index]
|
property var extruder: (base.activeMachine === null) ? null : activeMachine.extruderList[model.index]
|
||||||
NozzleMenu { title: Cura.MachineManager.activeDefinitionVariantsName; visible: Cura.MachineManager.activeMachine.hasVariants; extruderIndex: index }
|
NozzleMenu { title: Cura.MachineManager.activeDefinitionVariantsName; visible: Cura.MachineManager.activeMachine.hasVariants; extruderIndex: index }
|
||||||
MaterialMenu { title: catalog.i18nc("@title:menu", "&Material"); visible: Cura.MachineManager.activeMachine.hasMaterials; extruderIndex: index }
|
MaterialMenu
|
||||||
|
{
|
||||||
|
title: catalog.i18nc("@title:menu", "&Material")
|
||||||
|
visible: Cura.MachineManager.activeMachine.hasMaterials
|
||||||
|
extruderIndex: index
|
||||||
|
updateModels: false
|
||||||
|
onAboutToShow: updateModels = true
|
||||||
|
onAboutToHide: updateModels = false
|
||||||
|
}
|
||||||
|
|
||||||
MenuSeparator
|
MenuSeparator
|
||||||
{
|
{
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue