fix(ui/modules/Common/Form/ListForm): add same magic code at a lower depth...

This commit is contained in:
Ronan Abhamon 2017-02-20 10:50:53 +01:00
parent 241049e93b
commit dfd0516399

View file

@ -176,7 +176,17 @@ RowLayout {
Component.onCompleted: {
if ($value.length === 0) {
textInput.forceActiveFocus()
// FIXME: Find the source of this problem.
//
// Magic code. If it's the first inserted value,
// an event or a callback steal the item focus.
// I suppose it's an internal Qt qml event...
//
// So, I choose to run a callback executed after this
// internal event.
Utils.setTimeout(listForm, 0, function () {
textInput.forceActiveFocus()
})
}
}
}