Loading packages/SystemUI/res/values/dimens.xml +1 −0 Original line number Diff line number Diff line Loading @@ -37,6 +37,7 @@ <!-- Used while animating the navbar during a long press. --> <dimen name="navigation_home_handle_additional_width_for_animation">20dp</dimen> <dimen name="navigation_home_handle_additional_height_for_animation">4dp</dimen> <dimen name="navigation_home_handle_shrink_width_for_animation">16dp</dimen> <!-- Size of the nav bar edge panels, should be greater to the edge sensitivity + the drag threshold --> Loading packages/SystemUI/shared/src/com/android/systemui/shared/recents/ISystemUiProxy.aidl +2 −1 Original line number Diff line number Diff line Loading @@ -149,10 +149,11 @@ interface ISystemUiProxy { * * @param isTouchDown {@code true} if the button is starting to be pressed ({@code false} if * released or canceled) * @param shrink {@code true} if the handle should shrink, {@code false} if it should grow * @param durationMs how long the animation should take (for the {@code isTouchDown} case, this * should be the same as the amount of time to trigger a long-press) */ oneway void animateNavBarLongPress(boolean isTouchDown, long durationMs) = 54; oneway void animateNavBarLongPress(boolean isTouchDown, boolean shrink, long durationMs) = 54; // Next id = 55 } packages/SystemUI/src/com/android/systemui/navigationbar/NavigationBar.java +2 −2 Original line number Diff line number Diff line Loading @@ -400,8 +400,8 @@ public class NavigationBar extends ViewController<NavigationBarView> implements } @Override public void animateNavBarLongPress(boolean isTouchDown, long durationMs) { mView.getHomeHandle().animateLongPress(isTouchDown, durationMs); public void animateNavBarLongPress(boolean isTouchDown, boolean shrink, long durationMs) { mView.getHomeHandle().animateLongPress(isTouchDown, shrink, durationMs); } @Override Loading packages/SystemUI/src/com/android/systemui/navigationbar/buttons/ButtonDispatcher.java +2 −2 Original line number Diff line number Diff line Loading @@ -247,10 +247,10 @@ public class ButtonDispatcher { } } public void animateLongPress(boolean isTouchDown, long durationMs) { public void animateLongPress(boolean isTouchDown, boolean shrink, long durationMs) { for (int i = 0; i < mViews.size(); i++) { if (mViews.get(i) instanceof ButtonInterface) { ((ButtonInterface) mViews.get(i)).animateLongPress(isTouchDown, durationMs); ((ButtonInterface) mViews.get(i)).animateLongPress(isTouchDown, shrink, durationMs); } } } Loading packages/SystemUI/src/com/android/systemui/navigationbar/buttons/ButtonInterface.java +5 −4 Original line number Diff line number Diff line Loading @@ -36,8 +36,9 @@ public interface ButtonInterface { * * @param isTouchDown {@code true} if the button is starting to be pressed ({@code false} if * released or canceled) * @param shrink {@code true} if the handle should shrink, {@code false} if it should grow * @param durationMs how long the animation should take (for the {@code isTouchDown} case, this * should be the same as the amount of time to trigger a long-press) */ default void animateLongPress(boolean isTouchDown, long durationMs) {} default void animateLongPress(boolean isTouchDown, boolean shrink, long durationMs) {} } Loading
packages/SystemUI/res/values/dimens.xml +1 −0 Original line number Diff line number Diff line Loading @@ -37,6 +37,7 @@ <!-- Used while animating the navbar during a long press. --> <dimen name="navigation_home_handle_additional_width_for_animation">20dp</dimen> <dimen name="navigation_home_handle_additional_height_for_animation">4dp</dimen> <dimen name="navigation_home_handle_shrink_width_for_animation">16dp</dimen> <!-- Size of the nav bar edge panels, should be greater to the edge sensitivity + the drag threshold --> Loading
packages/SystemUI/shared/src/com/android/systemui/shared/recents/ISystemUiProxy.aidl +2 −1 Original line number Diff line number Diff line Loading @@ -149,10 +149,11 @@ interface ISystemUiProxy { * * @param isTouchDown {@code true} if the button is starting to be pressed ({@code false} if * released or canceled) * @param shrink {@code true} if the handle should shrink, {@code false} if it should grow * @param durationMs how long the animation should take (for the {@code isTouchDown} case, this * should be the same as the amount of time to trigger a long-press) */ oneway void animateNavBarLongPress(boolean isTouchDown, long durationMs) = 54; oneway void animateNavBarLongPress(boolean isTouchDown, boolean shrink, long durationMs) = 54; // Next id = 55 }
packages/SystemUI/src/com/android/systemui/navigationbar/NavigationBar.java +2 −2 Original line number Diff line number Diff line Loading @@ -400,8 +400,8 @@ public class NavigationBar extends ViewController<NavigationBarView> implements } @Override public void animateNavBarLongPress(boolean isTouchDown, long durationMs) { mView.getHomeHandle().animateLongPress(isTouchDown, durationMs); public void animateNavBarLongPress(boolean isTouchDown, boolean shrink, long durationMs) { mView.getHomeHandle().animateLongPress(isTouchDown, shrink, durationMs); } @Override Loading
packages/SystemUI/src/com/android/systemui/navigationbar/buttons/ButtonDispatcher.java +2 −2 Original line number Diff line number Diff line Loading @@ -247,10 +247,10 @@ public class ButtonDispatcher { } } public void animateLongPress(boolean isTouchDown, long durationMs) { public void animateLongPress(boolean isTouchDown, boolean shrink, long durationMs) { for (int i = 0; i < mViews.size(); i++) { if (mViews.get(i) instanceof ButtonInterface) { ((ButtonInterface) mViews.get(i)).animateLongPress(isTouchDown, durationMs); ((ButtonInterface) mViews.get(i)).animateLongPress(isTouchDown, shrink, durationMs); } } } Loading
packages/SystemUI/src/com/android/systemui/navigationbar/buttons/ButtonInterface.java +5 −4 Original line number Diff line number Diff line Loading @@ -36,8 +36,9 @@ public interface ButtonInterface { * * @param isTouchDown {@code true} if the button is starting to be pressed ({@code false} if * released or canceled) * @param shrink {@code true} if the handle should shrink, {@code false} if it should grow * @param durationMs how long the animation should take (for the {@code isTouchDown} case, this * should be the same as the amount of time to trigger a long-press) */ default void animateLongPress(boolean isTouchDown, long durationMs) {} default void animateLongPress(boolean isTouchDown, boolean shrink, long durationMs) {} }