mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-02 08:56:55 +00:00
Show taskbar pinning dialog on right-click.
Fix: 308768942 Test: Manual. Flag: ACONFIG com.android.launcher3.enable_taskbar_pinning DISABLED Change-Id: I37e49452fada944186c8300562061bf9650a0d0a
This commit is contained in:
@@ -44,6 +44,7 @@ import android.animation.ValueAnimator;
|
||||
import android.annotation.NonNull;
|
||||
import android.graphics.Rect;
|
||||
import android.util.Log;
|
||||
import android.view.InputDevice;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.animation.Interpolator;
|
||||
@@ -883,6 +884,17 @@ public class TaskbarViewController implements TaskbarControllers.LoggableTaskbar
|
||||
};
|
||||
}
|
||||
|
||||
public View.OnTouchListener getTaskbarDividerRightClickListener() {
|
||||
return (v, event) -> {
|
||||
if (event.isFromSource(InputDevice.SOURCE_MOUSE)
|
||||
&& event.getButtonState() == MotionEvent.BUTTON_SECONDARY) {
|
||||
mControllers.taskbarPinningController.showPinningView(v);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
};
|
||||
}
|
||||
|
||||
public View.OnLongClickListener getIconOnLongClickListener() {
|
||||
return mControllers.taskbarDragController::startDragOnLongClick;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user