Skip to content

fixes "shake to undo" gesture bug. #64

Open
esemusa wants to merge 1 commit into
IdleHandsApps:masterfrom
esemusa:bugfix/shake_to_undo
Open

fixes "shake to undo" gesture bug. #64
esemusa wants to merge 1 commit into
IdleHandsApps:masterfrom
esemusa:bugfix/shake_to_undo

Conversation

@esemusa

@esemusa esemusa commented Jun 11, 2019

Copy link
Copy Markdown

References Issue #55

The avoidingView was not moving back to the original position after "undo typing" click.

Basically, the problem is after the "undo typing" click the keyboardWillChangeFrameNotification observer will be called three times:
1 time: target to show the keyboard
2 time: target to hide the keyboard
3 time: target to show the keyboard

The third call will be executed bevor the "restore state" animation from the second call is finished. Therefore in the third call, all auto location are still saved in updatedConstraints & updatedConstraintConstants. So we need to wait for the animation to finish and then call didChange with the preserved notification object.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant