package net.kwmt27.codesearch.util;

import android.content.Context;
import android.content.res.TypedArray;
import android.view.View;

import net.kwmt27.codesearch.R;

public class ViewUtil {

    public static void setRippleDrawable(Context context, View view) {
        int[] attrs = new int[]{R.attr.selectableItemBackground};
        TypedArray typedArray = context.obtainStyledAttributes(attrs);
        int backgroundResource = typedArray.getResourceId(0, 0);
        view.setBackgroundResource(backgroundResource);
    }

}

@@ -185,16 +185,159 @@
 wUtil %7B%0A
+    // http://stackoverflow.com/documentation/android/124/material-design-for-all-android-versions/14200/rippledrawable#t=201608061421545473182
 %0A    pub

add reference url