From f823a98708dd3eed2485ff412d3fe2dd03a31f35 Mon Sep 17 00:00:00 2001 From: Aleksei S Date: Mon, 15 Jan 2018 15:39:25 +0100 Subject: [PATCH] Fix: Cura update setting after delay CURA-4785 --- .../{AutoSave => BigFlameGraph}/plugin.json | 0 resources/qml/Settings/SettingTextField.qml | 21 +++++++++++-------- 2 files changed, 12 insertions(+), 9 deletions(-) rename plugins/{AutoSave => BigFlameGraph}/plugin.json (100%) diff --git a/plugins/AutoSave/plugin.json b/plugins/BigFlameGraph/plugin.json similarity index 100% rename from plugins/AutoSave/plugin.json rename to plugins/BigFlameGraph/plugin.json diff --git a/resources/qml/Settings/SettingTextField.qml b/resources/qml/Settings/SettingTextField.qml index 176a4e23e6..cf5d1cd7f0 100644 --- a/resources/qml/Settings/SettingTextField.qml +++ b/resources/qml/Settings/SettingTextField.qml @@ -102,6 +102,17 @@ SettingItem TextInput { + Timer + { + id: inputTimer + interval: 1000 + running: false + repeat: false + onTriggered: { + propertyProvider.setPropertyValue("value", input.text) + } + } + id: input anchors @@ -131,15 +142,7 @@ SettingItem } if (textHasChanged) { - propertyProvider.setPropertyValue("value", text) - } - } - - onEditingFinished: - { - if (textHasChanged) - { - propertyProvider.setPropertyValue("value", text) + inputTimer.restart() } }