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

Commit 28c4a0bb authored by Alan Viverette's avatar Alan Viverette
Browse files

Allow activities to handle density configuration changes

Some activities, like the density preference dialog in Settings, may need
to implement custom handling of display density changes.

This corresponds to the bit specified in ActivityInfo.CONFIG_NATIVE_BITS.

Change-Id: Idd4b9ec11a217b1f9af847d7ed8a6f3639e1f8ee
parent 67de4945
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -627,9 +627,9 @@ public class ActivityInfo extends ComponentInfo
     * {@link #CONFIG_MCC}, {@link #CONFIG_MNC},
     * {@link #CONFIG_LOCALE}, {@link #CONFIG_TOUCHSCREEN},
     * {@link #CONFIG_KEYBOARD}, {@link #CONFIG_NAVIGATION},
     * {@link #CONFIG_ORIENTATION}, {@link #CONFIG_SCREEN_LAYOUT} and
     * {@link #CONFIG_LAYOUT_DIRECTION}.  Set from the {@link android.R.attr#configChanges}
     * attribute.
     * {@link #CONFIG_ORIENTATION}, {@link #CONFIG_SCREEN_LAYOUT},
     * {@link #CONFIG_DENSITY}, and {@link #CONFIG_LAYOUT_DIRECTION}.
     * Set from the {@link android.R.attr#configChanges} attribute.
     */
    public int configChanges;

+4 −0
Original line number Diff line number Diff line
@@ -793,6 +793,10 @@
             physical screen size has changed such as switching to an external
             display. -->
        <flag name="smallestScreenSize" value="0x0800" />
        <!-- The display density has changed. This might be caused by the user
             specifying a different display scale, or it might be caused by a
             different display being activated. -->
        <flag name="density" value="0x1000" />
        <!-- The layout direction has changed. For example going from LTR to RTL. -->
        <flag name="layoutDirection" value="0x2000" />
        <!-- The font scaling factor has changed, that is the user has