summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
author Fabian Kozynski <kozynski@google.com> 2021-05-13 12:39:09 -0400
committer Fabian Kozynski <kozynski@google.com> 2021-05-14 11:19:08 -0400
commit5a428fb90ed887ae651f15910c4befda5fe7b0ee (patch)
tree804085d5149988943ce49e6a5c09791e5d7e65ac
parent28c4860610d4cc96c29849e5d75cf78b15223ad6 (diff)
Do not disappear text when moving tiles
Also, clear animation when tiles fail to recycle. Fixes: 176699404 Fixes: 187909227 Test: Manual Change-Id: I5cff76a6b65f3ae96e78cb01a025fa83612a6587
-rw-r--r--packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java23
1 files changed, 1 insertions, 22 deletions
diff --git a/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java b/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
index 12c6906d87f7..ba65d5163881 100644
--- a/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
+++ b/packages/SystemUI/src/com/android/systemui/qs/customize/TileAdapter.java
@@ -291,6 +291,7 @@ public class TileAdapter extends RecyclerView.Adapter<Holder> implements TileSta
@Override
public boolean onFailedToRecycleView(Holder holder) {
+ holder.stopDrag();
holder.clearDrag();
return true;
}
@@ -565,12 +566,6 @@ public class TileAdapter extends RecyclerView.Adapter<Holder> implements TileSta
public void clearDrag() {
itemView.clearAnimation();
- if (mTileView instanceof CustomizeTileView) {
- mTileView.findViewById(R.id.tile_label).clearAnimation();
- mTileView.findViewById(R.id.tile_label).setAlpha(1);
- mTileView.getSecondaryLabel().clearAnimation();
- mTileView.getSecondaryLabel().setAlpha(.6f);
- }
}
public void startDrag() {
@@ -578,14 +573,6 @@ public class TileAdapter extends RecyclerView.Adapter<Holder> implements TileSta
.setDuration(DRAG_LENGTH)
.scaleX(DRAG_SCALE)
.scaleY(DRAG_SCALE);
- if (mTileView instanceof CustomizeTileView) {
- mTileView.findViewById(R.id.tile_label).animate()
- .setDuration(DRAG_LENGTH)
- .alpha(0);
- mTileView.getSecondaryLabel().animate()
- .setDuration(DRAG_LENGTH)
- .alpha(0);
- }
}
public void stopDrag() {
@@ -593,14 +580,6 @@ public class TileAdapter extends RecyclerView.Adapter<Holder> implements TileSta
.setDuration(DRAG_LENGTH)
.scaleX(1)
.scaleY(1);
- if (mTileView instanceof CustomizeTileView) {
- mTileView.findViewById(R.id.tile_label).animate()
- .setDuration(DRAG_LENGTH)
- .alpha(1);
- mTileView.getSecondaryLabel().animate()
- .setDuration(DRAG_LENGTH)
- .alpha(.6f);
- }
}
boolean canRemove() {