Closed AndroidDeveloperLB closed 1 year ago
wait, but we already have this
We have? Odd. I didn't see it warn about it. Do I have to enable it , or is it enabled by default? How is it called? I will check if it's enabled or not.
“Useless resource element” inspection
It's manual or automatic? Should just opening the layout file show the warning?
The inspection is enabled by default and works automatically.
It it doesn't work in your case, and Gradle is synced, then there's a bug, please post your code here.
Sorry for some reason the plugin wasn't installed anymore. No idea why. Now works fine
If I have in a layout XML a value for "padding", and also for "paddingBottom", sadly the "paddingBottom" doesn't do anything.
I sometimes make this mistake, because I think to myself : "I've created a general rule, and also an exception to the rule".
In this case, the proper way to fix it is to split the "padding" to "paddingHorizontal" and "paddingTop", so that "paddingBottom" would do what it's supposed to do.
I don't remember how it works for margins.
Please offer a warning about such a case and similar cases.