mirror of
https://github.com/LawnchairLauncher/lawnchair.git
synced 2026-03-01 16:26:47 +00:00
Removing various reflection based animations, to allow for better proguarding
Change-Id: If9df24ea4170e8a3d336057d1c3dc800934fc1ac
This commit is contained in:
@@ -21,6 +21,7 @@ import static com.android.launcher3.Utilities.SINGLE_FRAME_MS;
|
||||
import android.content.Context;
|
||||
import android.graphics.Rect;
|
||||
import android.util.AttributeSet;
|
||||
import android.util.Property;
|
||||
import android.view.MotionEvent;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
@@ -42,6 +43,32 @@ import java.util.ArrayList;
|
||||
public abstract class BaseDragLayer<T extends Context & ActivityContext>
|
||||
extends InsettableFrameLayout {
|
||||
|
||||
public static final Property<LayoutParams, Integer> LAYOUT_X =
|
||||
new Property<LayoutParams, Integer>(Integer.TYPE, "x") {
|
||||
@Override
|
||||
public Integer get(LayoutParams lp) {
|
||||
return lp.x;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void set(LayoutParams lp, Integer x) {
|
||||
lp.x = x;
|
||||
}
|
||||
};
|
||||
|
||||
public static final Property<LayoutParams, Integer> LAYOUT_Y =
|
||||
new Property<LayoutParams, Integer>(Integer.TYPE, "y") {
|
||||
@Override
|
||||
public Integer get(LayoutParams lp) {
|
||||
return lp.y;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void set(LayoutParams lp, Integer y) {
|
||||
lp.y = y;
|
||||
}
|
||||
};
|
||||
|
||||
protected final int[] mTmpXY = new int[2];
|
||||
protected final Rect mHitRect = new Rect();
|
||||
|
||||
@@ -307,38 +334,6 @@ public abstract class BaseDragLayer<T extends Context & ActivityContext>
|
||||
public LayoutParams(ViewGroup.LayoutParams lp) {
|
||||
super(lp);
|
||||
}
|
||||
|
||||
public void setWidth(int width) {
|
||||
this.width = width;
|
||||
}
|
||||
|
||||
public int getWidth() {
|
||||
return width;
|
||||
}
|
||||
|
||||
public void setHeight(int height) {
|
||||
this.height = height;
|
||||
}
|
||||
|
||||
public int getHeight() {
|
||||
return height;
|
||||
}
|
||||
|
||||
public void setX(int x) {
|
||||
this.x = x;
|
||||
}
|
||||
|
||||
public int getX() {
|
||||
return x;
|
||||
}
|
||||
|
||||
public void setY(int y) {
|
||||
this.y = y;
|
||||
}
|
||||
|
||||
public int getY() {
|
||||
return y;
|
||||
}
|
||||
}
|
||||
|
||||
protected void onLayout(boolean changed, int l, int t, int r, int b) {
|
||||
|
||||
Reference in New Issue
Block a user