Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public class MyPref extends Preference {
- private static final String TAG = "MyPref";
- public MyPref(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
- @Override
- protected void onBindView(View view) {
- super.onBindView(view);
- View v = view.findViewById(android.R.id.widget_frame);
- if (v != null) {
- v.setVisibility(View.VISIBLE);
- GradientDrawable d = new GradientDrawable();
- d.setCornerRadius(12);
- d.setColor(0xaaff0000);
- v.setBackground(d);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement