Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

android int color = ContextCompat.getColor(getContext(), mColorResourceId);

LinearLayout linearLayout = (LinearLayout) findViewById(R.id.linear);
int color = ContextCompat.getColor(getContext(), mColorResourceId);
linearLayout.setBackgroundColor(color);
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #android #int #color
ADD COMMENT
Topic
Name
7+2 =