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

Commit 0e1affa1 authored by Steve Kondik's avatar Steve Kondik Committed by Gerrit Code Review
Browse files

Merge "Allow font scaling setting persist" into gingerbread

parents 25704541 22a20891
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -311,7 +311,7 @@ public final class Configuration implements Parcelable, Comparable<Configuration
     * Set this object to the system defaults.
     */
    public void setToDefaults() {
        fontScale = 1;
        fontScale = 0;
        mcc = mnc = 0;
        locale = null;
        userSetLocale = false;
+3 −0
Original line number Diff line number Diff line
@@ -1305,6 +1305,9 @@ public class Resources {
                mMetrics.updateMetrics(mCompatibilityInfo,
                        mConfiguration.orientation, mConfiguration.screenLayout);
            }
            if (mConfiguration.fontScale <= 0 ) {
                mConfiguration.fontScale = 1;
            }
            mMetrics.scaledDensity = mMetrics.density * mConfiguration.fontScale;

            String locale = null;
+1 −1
Original line number Diff line number Diff line
@@ -1081,7 +1081,7 @@ public final class Settings {
        public static void getConfiguration(ContentResolver cr, Configuration outConfig) {
            outConfig.fontScale = Settings.System.getFloat(
                cr, FONT_SCALE, outConfig.fontScale);
            if (outConfig.fontScale < 0) {
            if (outConfig.fontScale <= 0) {
                outConfig.fontScale = 1;
            }
        }