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

Commit 00f7e884 authored by Mohammed Althaf T's avatar Mohammed Althaf T 😊
Browse files

camera: Turn off edge mode algorithm for one

- Over sharpen images
parent 3f4c1134
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -31,4 +31,11 @@ public class DeviceSettings {
        final boolean is_GS290 = Build.DEVICE != null && Build.DEVICE.equals("GS290");
        return is_fairphone || is_xiaomi || is_GS290;
    }

    public static boolean isMurenaOne() {
        final boolean isMurena = Build.MANUFACTURER.equals("Secure_Phone")
                || Build.MANUFACTURER.equals("Murena");
        final boolean isOne = Build.DEVICE.equals("one") || Build.DEVICE.equals("X2");
        return isMurena && isOne;
    }
}
+10 −2
Original line number Diff line number Diff line
@@ -380,11 +380,20 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen
        if( MyDebug.LOG )
            Log.d(TAG, "onCreate: time after updating folder history: " + (System.currentTimeMillis() - debug_time));

        SharedPreferences.Editor editor = sharedPreferences.edit();
        if (DeviceSettings.isMurenaOne()) {
            boolean isFirstTime = sharedPreferences.getBoolean("isFirstTimeMurenaOne", true);
            if (isFirstTime && applicationInterface.getEdgeModePref().equals("default")) {
                editor.putString(PreferenceKeys.EdgeModePreferenceKey, "off");
                editor.putBoolean("isFirstTimeMurenaOne", false);
                editor.apply();
            }
        }

        boolean isFirstTimeSaveLocation = sharedPreferences.getBoolean("isFirstTimeSaveLocation", true);
        String save_location = sharedPreferences.getString(PreferenceKeys.SaveLocationPreferenceKey, "Camera");

        if (isFirstTimeSaveLocation && save_location.equals("OpenCamera")) {
            SharedPreferences.Editor editor = sharedPreferences.edit();
            editor.putString(PreferenceKeys.SaveLocationPreferenceKey, "Camera");
            editor.putBoolean("isFirstTimeSaveLocation", false);
            editor.apply();
@@ -704,7 +713,6 @@ public class MainActivity extends AppCompatActivity implements PreferenceFragmen
                // We set the latest_version whether or not the dialog is shown - if we showed the first time dialog, we don't
                // want to then show the What's New dialog next time we run! Similarly if the user had disabled showing the dialog,
                // but then enables it, we still shouldn't show the dialog until the new time Open Camera upgrades.
                SharedPreferences.Editor editor = sharedPreferences.edit();
                editor.putInt(PreferenceKeys.LatestVersionPreferenceKey, version_code);
                editor.apply();
            }