mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-19 18:58:19 +00:00
Go back to previous state when hitting back from discovery bounce
Normally when you hit back, we just close the floating view if there is one. This makes less sense for DiscoveryBounce, since it doesn't feel like a different state even though it's technically a floating view. So in that case, don't consume the back press; let launcher handle it to go to the previous state. Bug: 80075741 Change-Id: I7270b61be70509cb2101400a12929478a5d082aa
This commit is contained in:
@@ -121,9 +121,11 @@ public abstract class AbstractFloatingView extends LinearLayout implements Touch
|
||||
|
||||
protected abstract boolean isOfType(@FloatingViewType int type);
|
||||
|
||||
public void onBackPressed() {
|
||||
/** @return Whether the back is consumed. If false, Launcher will handle the back as well. */
|
||||
public boolean onBackPressed() {
|
||||
logActionCommand(Action.Command.BACK);
|
||||
close(true);
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user