-
Notifications
You must be signed in to change notification settings - Fork 275
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
Non-Constant Fields in Case Labels #683
Comments
@chirag-jn @cpg Hey can I work on this issue instead of Localisation Support? (#548 ).Please guide me where to start first as I new to code base of Amahi android. |
Sure you can work on this. |
The Android documentation link would be a good place to let you know about the issue. |
@chirag-jn @cpg I have found 2 solutions for this issue. Please tell which is better so I can start implementing it.
|
In the first case, you are only disabling linting for NonConstantResourceId. That still leaves it as a pain point in future versions of Gradle. However, the second option seems great! |
@chirag-jn Okay I am implementing second option. Thanks for your suggestion! |
@chirag-jn @cpg I have sent a PR ( #685 ) for this issue please review it. I closed this PR due to some error. |
@chirag-jn @cpg This is the new PR( #689 ) for this issue please review it. |
Describe the issue
With the introduction of Gradle 5.0, resource IDs won't be final anymore. Hence, a switch-case statement won't work in onClick function for view elements. We have to switch to if-else conditions of a view binding strategy for mapping resource IDs to their variables.
More information: http://tools.android.com/tips/non-constant-fields
For the first case, we have to switch from
to something like this:
Old view binding libraries like JakeWharton/butterknife won't work anymore either.
The text was updated successfully, but these errors were encountered: