We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 3305 - [Patch] Fixed TextInput status when the keyboard was dismissed with the dismiss key on the iPad
Summary: [Patch] Fixed TextInput status when the keyboard was dismissed with the dismi...
Status: RESOLVED FIXED
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: HG 2.1
Hardware: iPhone/iPod touch iOS (All)
: P2 normal
Assignee: Sam Lantinga
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-04-05 15:27 UTC by Diego
Modified: 2016-12-02 10:22 UTC (History)
0 users

See Also:


Attachments
dismiss keyboard patch (380 bytes, patch)
2016-04-05 15:27 UTC, Diego
Details | Diff
dismiss keyboard patch fix (1.85 KB, patch)
2016-12-01 19:54 UTC, Diego
Details | Diff
dismiss keyboard and macro fix (2.02 KB, patch)
2016-12-01 22:06 UTC, Diego
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Diego 2016-04-05 15:27:40 UTC
Created attachment 2407 [details]
dismiss keyboard patch

The keyboard on iPads has a dismiss button that hides the keyboard. When the keyboard was hidden using that button, instead of the return key, SDL was still reporting IsTextInputActive as true. This patch adds an extra SDL_StopTextInput when iOS reports the keyboard will hide.
Comment 1 Sam Lantinga 2016-10-01 19:46:54 UTC
Fixed, thanks!
https://hg.libsdl.org/SDL/rev/ff5f3b3e6940
Comment 2 Diego 2016-12-01 19:54:01 UTC
Created attachment 2642 [details]
dismiss keyboard patch fix

I was previously unaware that rotating the device to a different orientation when the keyboard is shown causes a keyboardWillHide followed by a keyboardWillShow notification. The previous patch would then mistakenly StopTextInput when rotating. This patch fixes that by checking if the device is rotating before stopping text input.
Comment 3 Diego 2016-12-01 19:55:15 UTC
Reopening
Comment 4 Diego 2016-12-01 22:06:09 UTC
Created attachment 2643 [details]
dismiss keyboard and macro fix

This update corrects and explains the deprecated macro check.
Comment 5 Sam Lantinga 2016-12-02 10:22:00 UTC
Good catch, thanks!