Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit fe3669fa authored by narinder Rana's avatar narinder Rana
Browse files

update key hide_notificationIcon_left_system_icon as in lineageOS Sdk

parent 2cb49f56
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -99,7 +99,7 @@
<!--             />-->

        <lineageos.preference.HideNotificationSwitchPreference
            android:key="hide_notification_icons"
            android:key="hide_notificationIcon_left_system_icon"
            android:title="@string/hide_notification_icons"
           />
<!--        android:summary="@string/heads_up_notifications_enabled_summary"-->
+59 −0
Original line number Diff line number Diff line
@@ -49,15 +49,22 @@ public class HideNotificationIconsPreferenceController extends TogglePreferenceC

        super(context, preferenceKey);

        Log.e("Setting....", "Setting ...HideNotificationIconsPreferenceController.................. ");
    }

    @Override
    public int getAvailabilityStatus() {
        Log.e("Setting....", "Setting ...getAvailabilityStatus.................. ");

        return AVAILABLE;
    }

    @Override
    public boolean isChecked() {


        Log.e("Setting....", "Setting ...isChecked.................. ");

        return Settings.Secure.getInt(mContext.getContentResolver(),
                LineageSettings.System.HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON, OFF) == ON;
    }
@@ -75,4 +82,56 @@ public class HideNotificationIconsPreferenceController extends TogglePreferenceC
        return out;
    }

//
//
//
//        AbstractPreferenceController
//        implements PreferenceControllerMixin, Preference.OnPreferenceChangeListener {
//
//            static final String HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON = "hide_notificationIcon_left_system_icon";
//
//    public HideNotificationIconsPreferenceController(Context context) {
//                super(context);
//            }
//
//
//            @Override
//            public boolean isAvailable() {
//                Log.e("Setting....", "Setting ...isAvailable ");
//                // LineageSettings.System.HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON;
//                return true;
//            }
//
//            @Override
//            public String getPreferenceKey() {
//                Log.e("Setting....", "Setting ...getPreferenceKey ");
//                return HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON;
//            }
//
//            @Override
//            public void updateState(Preference preference) {
//                Log.e("Setting....", "Setting ...updateState ");
//                ((TwoStatePreference) preference).setChecked(LineageSettings.System.getInt(
//                        mContext.getContentResolver(),
//                        LineageSettings.System.HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON,
//                        0) == 1);
//
//
//            }
//
//
//
//            @Override
//            public boolean onPreferenceChange(Preference preference, Object newValue) {
//
//                Log.e("Setting....", "Setting ...onPreferenceChange ");
//                LineageSettings.System.putInt(
//                        mContext.getContentResolver(),
//                        LineageSettings.System.HIDE_NOTIFICATIONICON_LEFT_SYSTEM_ICON,
//                        (Boolean) newValue ? 1 : 0);
//                return true;
//    }



}