You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
enable onTouchEvent for ViewGroups and add some stubs
This commit is contained in:
@@ -1991,7 +1991,7 @@ public final class MotionEvent extends InputEvent {
|
||||
* that pointer identifier.
|
||||
*/
|
||||
public final int findPointerIndex(int pointerId) {
|
||||
return nativeFindPointerIndex(mNativePtr, pointerId);
|
||||
return 0 /*nativeFindPointerIndex(mNativePtr, pointerId)*/;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -9,4 +9,11 @@ public class VelocityTracker {
|
||||
public void addMovement(MotionEvent event) {}
|
||||
|
||||
public void recycle() {}
|
||||
|
||||
public void computeCurrentVelocity(int units, float maxVelocity) {}
|
||||
|
||||
public float getXVelocity(int id) {return 0.f;}
|
||||
public float getYVelocity(int id) {return 0.f;}
|
||||
|
||||
public void clear() {}
|
||||
}
|
||||
|
||||
@@ -1520,4 +1520,6 @@ public class View extends Object {
|
||||
}
|
||||
|
||||
public void setLayerType(int layerType, Paint paint) {}
|
||||
|
||||
public float getZ() {return 0.f;}
|
||||
}
|
||||
|
||||
@@ -302,6 +302,13 @@ public class ViewGroup extends View implements ViewParent, ViewManager {
|
||||
}
|
||||
}
|
||||
|
||||
protected boolean isChildrenDrawingOrderEnabled() { return false; }
|
||||
|
||||
@Override
|
||||
public boolean onStartNestedScroll(View child, View target, int nestedScrollAxes) {
|
||||
return false;
|
||||
}
|
||||
|
||||
public static class LayoutParams {
|
||||
public static final int FILL_PARENT = -1;
|
||||
public static final int MATCH_PARENT = -1;
|
||||
|
||||
@@ -6,4 +6,6 @@ public interface ViewParent {
|
||||
public boolean isLayoutRequested();
|
||||
|
||||
public void requestDisallowInterceptTouchEvent(boolean disallowIntercept);
|
||||
|
||||
public abstract boolean onStartNestedScroll(View child, View target, int nestedScrollAxes);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user