package cl.monsoon.s1next.widget;

import android.annotation.TargetApi;
import android.content.Context;
import android.os.Build;
import android.preference.ListPreference;
import android.util.AttributeSet;

/**
 * See https://android.googlesource.com/platform/frameworks/base/+/94c02a1a1a6d7e6900e5a459e9cc699b9510e5a2
 */
@SuppressWarnings("UnusedDeclaration")
public final class ListPreferenceCompat extends ListPreference {

    @TargetApi(Build.VERSION_CODES.LOLLIPOP)
    public ListPreferenceCompat(Context context, AttributeSet attrs, int defStyleAttr, int defStyleRes) {
        super(context, attrs, defStyleAttr, defStyleRes);
    }

    @TargetApi(Build.VERSION_CODES.LOLLIPOP)
    public ListPreferenceCompat(Context context, AttributeSet attrs, int defStyleAttr) {
        super(context, attrs, defStyleAttr);
    }

    public ListPreferenceCompat(Context context, AttributeSet attrs) {
        super(context, attrs);
    }

    public ListPreferenceCompat(Context context) {
        super(context);
    }

    /**
     * setValue() was not calling notifyChanged() before android-4.4,
     */
    @Override
    public void setValue(String value) {
        super.setValue(value);

        notifyChanged();
    }
}

@@ -428,48 +428,85 @@
     
-@TargetApi(Build.VERSION_CODES.LOLLIPOP)
+public ListPreferenceCompat(Context context) %7B%0A        super(context);%0A    %7D%0A
 %0A   
@@ -573,43 +573,8 @@
 ttrs
-, int defStyleAttr, int defStyleRes
 ) %7B%0A
@@ -605,35 +605,8 @@
 ttrs
-, defStyleAttr, defStyleRes
 );%0A 
@@ -789,32 +789,77 @@
 leAttr);%0A    %7D%0A%0A
+    @TargetApi(Build.VERSION_CODES.LOLLIPOP)%0A
     public ListP
@@ -913,122 +913,102 @@
 ttrs
-) %7B%0A        super(context, attrs);%0A    %7D%0A%0A    public ListPreferenceCompat(Context context) %7B%0A        super(context
+, int defStyleAttr, int defStyleRes) %7B%0A        super(context, attrs, defStyleAttr, defStyleRes
 );%0A 

Tweak order for constructors