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

Commit b0fe4cad authored by Matt Casey's avatar Matt Casey Committed by Android (Google) Code Review
Browse files

Merge "Add device default values for long press power and touch gesture" into sc-dev

parents 9a776349 ea1aac80
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -4980,6 +4980,11 @@
    <!-- List containing the allowed install sources for accessibility service. -->
    <string-array name="config_accessibility_allowed_install_source" translatable="false"/>

    <!-- Default value for Settings.ASSIST_LONG_PRESS_HOME_ENABLED -->
    <bool name="config_assistLongPressHomeEnabledDefault">true</bool>
    <!-- Default value for Settings.ASSIST_TOUCH_GESTURE_ENABLED -->
    <bool name="config_assistTouchGestureEnabledDefault">true</bool>

    <!-- The amount of dimming to apply to wallpapers with mid range luminance. 0 displays
         the wallpaper at full brightness. 1 displays the wallpaper as fully black. -->
    <item name="config_wallpaperDimAmount" format="float" type="dimen">0.05</item>
+3 −0
Original line number Diff line number Diff line
@@ -4394,5 +4394,8 @@
  <java-symbol type="dimen" name="starting_surface_icon_size" />
  <java-symbol type="dimen" name="starting_surface_default_icon_size" />

  <java-symbol type="bool" name="config_assistLongPressHomeEnabledDefault" />
  <java-symbol type="bool" name="config_assistTouchGestureEnabledDefault" />

  <java-symbol type="dimen" name="config_wallpaperDimAmount" />
</resources>
+6 −2
Original line number Diff line number Diff line
@@ -1447,10 +1447,14 @@ public class NavigationBar implements View.OnAttachStateChangeListener,
    private void updateAssistantEntrypoints() {
        mAssistantAvailable = mAssistManagerLazy.get()
                .getAssistInfoForUser(UserHandle.USER_CURRENT) != null;
        boolean longPressDefault = mContext.getResources().getBoolean(
                com.android.internal.R.bool.config_assistLongPressHomeEnabledDefault);
        mLongPressHomeEnabled = Settings.Secure.getInt(mContentResolver,
                Settings.Secure.ASSIST_LONG_PRESS_HOME_ENABLED, 1) != 0;
                Settings.Secure.ASSIST_LONG_PRESS_HOME_ENABLED, longPressDefault ? 1 : 0) != 0;
        boolean gestureDefault = mContext.getResources().getBoolean(
                com.android.internal.R.bool.config_assistTouchGestureEnabledDefault);
        mAssistantTouchGestureEnabled = Settings.Secure.getInt(mContentResolver,
                Settings.Secure.ASSIST_TOUCH_GESTURE_ENABLED, 1) != 0;
                Settings.Secure.ASSIST_TOUCH_GESTURE_ENABLED, gestureDefault ? 1 : 0) != 0;
        if (mOverviewProxyService.getProxy() != null) {
            try {
                mOverviewProxyService.getProxy().onAssistantAvailable(mAssistantAvailable