mirror of
https://git.mirrors.martin98.com/https://github.com/Ultimaker/Cura
synced 2025-07-25 06:54:26 +08:00
Recreate editingFinished signal behaviour without using TextArea::editingFinished
Apparently, editingFinished was only added in Qt 5.6, so we cannot use it. So we have to manually recreate the behaviour. Contributes to CURA-342
This commit is contained in:
parent
0745b3bbf5
commit
898c621b6f
@ -3,7 +3,6 @@
|
||||
|
||||
import QtQuick 2.1
|
||||
import QtQuick.Controls 1.1
|
||||
import QtQuick.Dialogs 1.2
|
||||
|
||||
Item
|
||||
{
|
||||
@ -28,7 +27,23 @@ Item
|
||||
|
||||
anchors.fill: parent
|
||||
|
||||
onEditingFinished: base.editingFinished()
|
||||
Keys.onReturnPressed:
|
||||
{
|
||||
base.editingFinished()
|
||||
}
|
||||
|
||||
Keys.onEnterPressed:
|
||||
{
|
||||
base.editingFinished()
|
||||
}
|
||||
|
||||
onActiveFocusChanged:
|
||||
{
|
||||
if(!activeFocus)
|
||||
{
|
||||
base.editingFinished()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Label
|
||||
|
Loading…
x
Reference in New Issue
Block a user