public void setButtonDrawable(Drawable d) {
        if (drawable != d) {
            if (drawable != null) {
                drawable.setCallback(null);
                unscheduleDrawable(drawable);
            }

            drawable = d;

            if (d != null) {
                d.setCallback(this);
                //d.setLayoutDirection(getLayoutDirection());
                if (d.isStateful()) {
                    d.setState(getDrawableState());
                }
                d.setVisible(getVisibility() == VISIBLE, false);
                setMinHeight(d.getIntrinsicHeight());
                updateButtonTint();
            }
        }
    }
public void setButtonDrawable ( Drawable d ) { if ( drawable != d ) { if ( drawable != null ) { drawable . setCallback ( null ) ; unscheduleDrawable ( drawable ) ; } drawable = d ; if ( d != null ) { d . setCallback ( this ) ; if ( d . isStateful ( ) ) { d . setState ( getDrawableState ( ) ) ; } d . setVisible ( getVisibility ( ) == VISIBLE , false ) ; setMinHeight ( d . getIntrinsicHeight ( ) ) ; updateButtonTint ( ) ; } } }
Set the button graphic to a given Drawable

@param d The Drawable to use as the button graphic