mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-08-12 19:49:00 +08:00
Select material from menu when user clicks on it
The main function of the menu, after all. Contributes to issue CURA-8640.
This commit is contained in:
parent
5df5d6c37d
commit
5a76cd1615
@ -179,7 +179,9 @@ Cura.MenuItem
|
||||
{
|
||||
id: materialTypeButton
|
||||
anchors.fill: parent
|
||||
|
||||
hoverEnabled: true
|
||||
acceptedButtons: Qt.NoButton
|
||||
|
||||
onEntered:
|
||||
{
|
||||
@ -289,8 +291,17 @@ Cura.MenuItem
|
||||
{
|
||||
id: materialColorButton
|
||||
anchors.fill: parent
|
||||
hoverEnabled: true
|
||||
|
||||
hoverEnabled: true
|
||||
onClicked:
|
||||
{
|
||||
Cura.MachineManager.setMaterial(extruderIndex, model.container_node);
|
||||
menuPopup.itemHovered = 0; //Close all of these menus.
|
||||
menuPopup.close();
|
||||
colorPopup.itemHovered = 0;
|
||||
colorPopup.close();
|
||||
materialMenu.close();
|
||||
}
|
||||
onEntered:
|
||||
{
|
||||
menuPopup.itemHovered += 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user