Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dialog has conflict with Keyboard dismiss event. #19

Open
musaab-qamar-zeeshan opened this issue Aug 17, 2021 · 7 comments
Open

Dialog has conflict with Keyboard dismiss event. #19

musaab-qamar-zeeshan opened this issue Aug 17, 2021 · 7 comments

Comments

@musaab-qamar-zeeshan
Copy link

When keyboard get dismissed then this dialog occurred only for a second and then get hidded. After that when tap a button to show it again, it do not appear until we change the context and come again to that view/screen.

@musaab-qamar-zeeshan
Copy link
Author

I think issue is with following line..

var window = getCurrentView == null
? UIApplication.SharedApplication.Windows.Last()
: getCurrentView.Invoke();
Since keyboard last appeared and get dismissed when button is pressed to show datepickerdialog.
When I dont click on textfield then this picker works fine....

@musaab-qamar-zeeshan
Copy link
Author

@alexsorokoletov can you suggest a quick hack for this issue, if any exists.....??

@alexsorokoletov
Copy link
Owner

Hi @musaab-qamar-zeeshan!
Thank you for opening the issue.

This is an open-source project and I am more than happy to accept a contribution that would fix the problem.
I'm not actively working on this project and the most recent releases were all based on contributions from other people like you.

To start with something, it would be great if you could provide additional information:

  • iOS version
  • Xamarin iOS version used to compile your app
  • A video that shows the problem

@MateuszLas421
Copy link

MateuszLas421 commented Aug 19, 2021

Hi, i have same problem. The problem is rare and occurs on specific iphones. I only know that the case happened on iOS 14.5 , 14.6 ,maybe also older.

VS for Mac 8.8.3(build 16)
Xamarin.iOS.DatePickerDialog 1.0.6 & 1.0.3

Another mac
VS for Mac 8.10.7 (build 17)
Xamarin.iOS 14.20.0.24
Xamarin.iOS.DatePickerDialog 1.0.6 & 1.0.3
Simulator Version 12.5.1 iPhone 12/8 iOS 14.5 /14.4

@MateuszLas421
Copy link

MateuszLas421 commented Aug 24, 2021

@alexsorokoletov @musaab-qamar-zeeshan
This issue is related to trying to force the keyboard to be turned off. If I try to disable the keyboard. DatePickerDialog also turns off.

Sample code :

      `  textField.ViewController().View.EndEditing(true);   //!!!!!!!  conflict   `

@alexsorokoletov
Copy link
Owner

@MateuszLas421 thanks for the sample code, Github done something weird with the formatting.

@alexsorokoletov
Copy link
Owner

Since this repo is a port of https://github.com/squimer/DatePickerDialog-iOS-Swift to Xamarin, has anyone tried to see if the same problem occurs in the Swift version?

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

No branches or pull requests

3 participants