Created
May 7, 2015 17:07
-
-
Save Android-s14/68cd46798c9bf2351890 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void clearParentsBackgrounds(View view) { | |
while (view != null) { | |
final ViewParent parent = view.getParent(); | |
if (parent instanceof View) { | |
view = (View) parent; | |
view.setBackgroundResource(android.graphics.Color.TRANSPARENT); | |
} else { | |
view = null; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment