From 894322a3a1d9c098a76cf2eec97a05f30a74dfe9 Mon Sep 17 00:00:00 2001 From: Christian Mollekopf Date: Sat, 18 Aug 2018 08:11:48 +0200 Subject: Hopefully fixed file dialogs on mac. There seems to be a problem with setting visible=true before the component is completed. The dialog doesn't have to wrapped in a component anyways, and we can just show it using open. --- views/people/qml/PersonComposer.qml | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'views/people') diff --git a/views/people/qml/PersonComposer.qml b/views/people/qml/PersonComposer.qml index ff24a456..19e8c56b 100644 --- a/views/people/qml/PersonComposer.qml +++ b/views/people/qml/PersonComposer.qml @@ -90,19 +90,18 @@ Flickable { color: "#00000000" onClicked: { - fileDialogComponent.createObject(parent) + fileDialog.open() } - Component { - id: fileDialogComponent - Dialogs.FileDialog { - id: fileDialog - visible: true - title: "Choose an Avatar" - selectFolder: false - onAccepted: { - //TODO - } + Dialogs.FileDialog { + id: fileDialog + title: qsTr("Choose an Avatar") + folder: shortcuts.home + selectFolder: false + selectExisting: true + selectMultiple: false + onAccepted: { + //TODO } } } -- cgit v1.2.3