List of usage examples for android.view View setForeground
public void setForeground(Drawable foreground)
From source file:Main.java
public static void setForeground(View view, Drawable drawable) { view.setForeground(drawable); }
From source file:com.facebook.litho.MountState.java
private static void setViewForeground(View view, ViewNodeInfo viewNodeInfo) { final Drawable foreground = viewNodeInfo.getForeground(); if (foreground != null) { if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M) { throw new IllegalStateException("MountState has a ViewNodeInfo with foreground however " + "the current Android version doesn't support foreground on Views"); }//from w w w. j a va2s.c o m view.setForeground(foreground); } }
From source file:com.facebook.litho.MountState.java
private static void unsetViewForeground(View view, ViewNodeInfo viewNodeInfo) { final Drawable foreground = viewNodeInfo.getForeground(); if (foreground != null) { if (Build.VERSION.SDK_INT < Build.VERSION_CODES.M) { throw new IllegalStateException("MountState has a ViewNodeInfo with foreground however " + "the current Android version doesn't support foreground on Views"); }// w ww . java2 s.co m view.setForeground(null); } }