Browse Source

Add animation when expand/collapse panel

Diego Prado Gesto 6 years ago
parent
commit
8e3fb6196d
1 changed files with 2 additions and 1 deletions
  1. 2 1
      resources/qml/ObjectSelector.qml

+ 2 - 1
resources/qml/ObjectSelector.qml

@@ -11,7 +11,6 @@ Item
 {
     id: objectSelector
     width: UM.Theme.getSize("objects_menu_size").width
-//    height: childrenRect.height
     property bool opened: UM.Preferences.getValue("cura/show_list_of_files")
 
     Button
@@ -51,6 +50,8 @@ Item
         visible: objectSelector.opened
         height: visible ? scroll.height : 0
 
+        Behavior on height { NumberAnimation { duration: 100 } }
+
         anchors.bottom: parent.bottom
 
         ScrollView