QML preferences: use Layout.preferredHeight within GridLayout

It's not recommended to set the height explicitly of an item in a layout. Use
Layout.preferredHeight instead

Signed-off-by: Rick Walsh <rickmwalsh@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Rick Walsh 2016-01-20 22:47:59 +11:00 committed by Dirk Hohndel
parent 471270437b
commit 85c57c005f

View file

@ -56,7 +56,7 @@ GridLayout {
Item { width: MobileComponents.Units.gridUnit; height: width }
Item {
height: saveButton.height
Layout.preferredHeight: saveButton.height
Layout.preferredWidth: saveButton.width
SubsurfaceButton {
id: saveButton