Android Toolbar color change
问题 I have an app which uses android.support.v7.widget.Toolbar . Every section of the app is a Fragment accessed through a support.v4.widget.DrawerLayout I need to change the Toolbar color depending on which section is shown (client particular needs). I defined some colors in the colors.xml so I can make something like: changeToolbarColor(R.color.section_one); /**/ private void changeToolbarColor(int color_res_id){ Integer colorTo = getResources().getColor(color_res_id); toolbar