Fix Integer Spin Controller not sending PropertyEditorGUIMessages::Bus::Handler::OnEditingFinished (#5942)

* IntWidgetHandler::CreateUI now registers and sends editingFinished event
* add tests for int spin control valueChanged and editingFinished signals

Signed-off-by: amzn-sean <75276488+amzn-sean@users.noreply.github.com>
This commit is contained in:
amzn-sean
2021-11-30 10:49:53 +00:00
committed by GitHub
parent 21cae1603a
commit 4424b4d51e
5 changed files with 85 additions and 1 deletions
@@ -169,6 +169,10 @@ namespace AzToolsFramework
{
AzToolsFramework::PropertyEditorGUIMessages::Bus::Broadcast(&PropertyEditorGUIMessages::Bus::Events::RequestWrite, newCtrl);
});
this->connect(newCtrl, &PropertyControl::editingFinished, this, [newCtrl]()
{
AzToolsFramework::PropertyEditorGUIMessages::Bus::Broadcast(&PropertyEditorGUIMessages::Bus::Handler::OnEditingFinished, newCtrl);
});
// note: Qt automatically disconnects objects from each other when either end is destroyed, no need to worry about delete.
// Set the value range to that of ValueType as clamped to the range of QtWidgetValueType