add bunch of new java APIs: mostly stubs or copied from AOSP

Many of these classes are only needed to be subclassed by androidx
support library, which is used in many android apps
This commit is contained in:
Julian Winkler
2023-08-17 10:46:24 +02:00
parent a8e39cd613
commit 82744e9e5e
87 changed files with 2746 additions and 46 deletions

View File

@@ -20,6 +20,12 @@ public class FrameLayout extends ViewGroup {
native_constructor(context);
}
public FrameLayout(Context context, AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
native_constructor(attrs);
}
public native void native_constructor(AttributeSet attrs);
public native void native_constructor(Context context);
@@ -30,7 +36,16 @@ public class FrameLayout extends ViewGroup {
addView(child, index, null);
}
@Override
public LayoutParams generateLayoutParams(AttributeSet attrs) {
return new LayoutParams(getContext(), attrs);
}
public static class LayoutParams extends ViewGroup.MarginLayoutParams {
public LayoutParams (Context c, AttributeSet attrs) {
super(c, attrs);
}
public LayoutParams(int width, int height) {
super(width, height);
}