I'm trying to work with android studio, and so far so good. However, it has yellow indexes, warnings, lightbulbs, (etc) all over the place!
Which is a problem. No, my code isn't actually filled with real warnings, it's mostly style nitpicking items such as "Simplify" FLAG_AUTOSAVE == false to !FLAG_AUTOSAVE
Which, no I don't want to do, that isn't my style, I like my code to be more clear at a glance.
Or actually incorrect advice like change the signature of an correctly overridden method. (well it is still version 1.x...)
Regardless if my style is perfect or not, I need these to go away So I can see the real warnings.
The latest version of Android Studio (2.1) seems to have a lot more flexibility with its warnings. Settings -> Editor -> Inspections has increased greatly. Then use the search feature to help find the warnings/errors you want to dis(en)able. Then click the checkboxes for the settings you like.
Don't forget to choose "Default" or "Project Default" in the drop-down box.
In this image I managed to find your specific issue (I completely agree with you about that one!) which I unchecked.
These warnings you are seeing are related to the 'Lint' Static Analysis tool.
Not sure about Android Studio, but you can usually right-click to eliminate a particular warning from being shown, or you can actually go into the Lint preferences and disable certain (or all) warnings from a central console.
I find those warnings generally very helpful, and encourage you to not dismiss them so quickly.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With