dogo / SCLAlertView

Beautiful animated Alert View. Written in Objective-C
MIT License
3.5k stars 534 forks source link

iPad keyboard covered by alert #300

Open pnome opened 3 years ago

pnome commented 3 years ago

I'm reposting this as a new issue as it didn't seem to get seen. Hopefully someone has an idea about whether it's fixable. I have my fingers crossed.

Describe the bug With an iPad in landscape, and a dialog with a text field, when tapping in the text field, the keyboard covers the buttons of the dialog.

To Reproduce Steps to reproduce the behavior:

Run the SCLAlertView-ObjectiveC example project on an iPad in landscape Tap the "Show Edit" option Tap in the text field You can see it happening here: https://www.loom.com/share/7bc2516ff71240faac702304714811f6 Expected behavior I expect the dialog to move up out of the way of the keyboard

Smartphone (please complete the following information):

Device: [e.g. iPhone6] OS: [e.g. iOS8.1] Version [e.g. 22] Additional context Notably, the same bug does not happen using the Swift SCLAlertView example code. Also, if you tap Show Edit, then change to another app, then return, and THEN tap in the text field, everything works fine. This is a very strange bug.

dogo commented 3 years ago

Could not reproduce @pnome

Evidence: https://user-images.githubusercontent.com/1487375/130983264-7b4eca70-90b4-48ba-a6d6-512e3fce3c27.mov

pnome commented 3 years ago

@dogo , thanks for taking a look. It's definitely still there. I noticed that in your screen recording you were on 10.3 simulator. Can you try it on iOS 14.5? That's where I'm seeing the bug.

Here's another screen recording showing how it works fine in the swift version, but still doesn't work in the ObjC version: https://loom.com/share/919793f4ff3040bfae160d26fc7191d9

Thanks, Joe

dogo commented 3 years ago

@pnome Could you please validate the fix/improve-keyboard-handling branch ??

pnome commented 3 years ago

Hi @dogo,

Thanks for looking into this. I'm not entirely sure how to test a specific branch. Could you let me know how I can install that branch via CocoaPods?

Or, is there a way I can download that branch and run the examples (like I did in the video)?

My wife is about to have baby, so I might not be able to get around to it for a few days. Best, Joe

dogo commented 3 years ago

Hi @pnome , in your podfile put this: pod 'SCLAlertView-Objective-C', :git => 'https://github.com/dogo/SCLAlertView.git', :branch => 'fix/improve-keyboard-handling'

and btw congrats! babies always make us happy

pnome commented 3 years ago

Hi @dogo, Sorry it took me a while to get around to this. I tested the example in the new branch and it's still buggy.

Please see this video: https://loom.com/share/5e6bdddaedbe46c684df5e0754e6f515

Thanks, Joe

pnome commented 1 year ago

Sorry it took me so long to get back to you. I didn't get an alert about your commit (maybe because there was no comment in the thread?) and I only just noticed that you'd made an edit. I'm afraid I tested the demo project and it still seems very broken - https://www.loom.com/share/034728fffe3b431ab2c38c3d4e42e258

Hoping there's a way to fix it. Thanks again, Joe