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

Support v24.2.0 compatibility #44

Closed
ronaldsmartin opened this issue Aug 19, 2016 · 1 comment
Closed

Support v24.2.0 compatibility #44

ronaldsmartin opened this issue Aug 19, 2016 · 1 comment
Assignees
Labels
Milestone

Comments

@ronaldsmartin
Copy link

ronaldsmartin commented Aug 19, 2016

Since updating my support library dependencies to 24.2.0, I am encountering the following error when trying start my IssueReporterActivity subclass:

java.lang.ClassCastException: android.widget.FrameLayout cannot be cast to android.support.design.widget.TextInputLayout
at com.heinrichreimersoftware.androidissuereporter.IssueReporterActivity.setGuestEmailRequired(IssueReporterActivity.java:298)

The error occurs when calling setGuestEmailRequired(true) in the IssueReporterActivity's onCreate() method. Omitting the method call prevents the error from occurring.

Everything was working fine on support v23.1.1, so it seems there was an internal change in TextInputEditText in the new version of the design support library?

Thanks again for your work, and please let me know if you need help with this.
I believe the easiest fix would be to add an ID to the enclosing TextInputLayout for the air_inputEmail TextInputEditText and use findViewById() to access it instead of casting inputEmail.getParent().

@heinrichreimer heinrichreimer self-assigned this Aug 19, 2016
@heinrichreimer heinrichreimer added this to the Release 1.2.7 milestone Aug 19, 2016
@heinrichreimer
Copy link
Owner

heinrichreimer commented Aug 19, 2016

Good spot! I'll look into that ASAP

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants