mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-02-28 15:56:49 +00:00
Simplifying color extraction registration logic
> Calulating correct location irrespective of transient state (scale/translation) > Removing extraction pause/resume logic > Simplifying location calculation and registration (only use one location instead of a list) Bug: 194732483 Test: Manual Change-Id: I255d83761bff5e09c9fb0a5e398d0be0c1d0956f
This commit is contained in:
@@ -217,7 +217,6 @@ public abstract class ButtonDropTarget extends TextView
|
||||
final DragView dragView = d.dragView;
|
||||
final Rect to = getIconRect(d);
|
||||
final float scale = (float) to.width() / dragView.getMeasuredWidth();
|
||||
dragView.disableColorExtraction();
|
||||
dragView.detachContentView(/* reattachToPreviousParent= */ true);
|
||||
mDropTargetBar.deferOnDragEnd();
|
||||
|
||||
@@ -225,9 +224,6 @@ public abstract class ButtonDropTarget extends TextView
|
||||
completeDrop(d);
|
||||
mDropTargetBar.onDragEnd();
|
||||
mLauncher.getStateManager().goToState(NORMAL);
|
||||
// Only re-enable updates once the workspace is back to normal, which will be after the
|
||||
// current frame.
|
||||
post(dragView::resumeColorExtraction);
|
||||
};
|
||||
|
||||
dragLayer.animateView(d.dragView, to, scale, 0.1f, 0.1f,
|
||||
|
||||
Reference in New Issue
Block a user