private void obtainDividerColor ( @ StyleRes final int themeResourceId ) { TypedArray typedArray = getContext ( ) . getTheme ( ) . obtainStyledAttributes ( themeResourceId , new int [ ] { R . attr . materialDialogDividerColor } ) ; int defaultColor = ContextCompat . getColor ( getContext ( ) , R . color . divider_color_light ) ; setDividerColor ( typedArray . getColor ( 0 , defaultColor ) ) ; }
Obtains the color of dividers from a specific theme .