Code example for ColorDrawable

Methods: getColor

0
	} 
 
	@TargetApi(Build.VERSION_CODES.HONEYCOMB)
	private int getColorFromColorDrawableHC(ColorDrawable colorDrawable)
	{ 
		return colorDrawable.getColor();
	} 
 
	public void setBackgroundColor(int value)
	{ 
		if (view == null) {
			Log.w(TAG, "Wrapped view is null. Cannot set background color.");
			return; 
		} 
		view.setBackgroundColor(value);
	} 
 
}