Add some missing APIs.

android.widget.Filter and android.webkit.MimeTypeMap are copied from
AOSP. Other new classes are only stub implementations.
This commit is contained in:
Julian Winkler
2023-09-01 12:55:04 +02:00
parent 6c2a3adae6
commit 97f8c2ed0f
30 changed files with 1165 additions and 38 deletions

View File

@@ -3,9 +3,8 @@ package android.widget;
import android.content.Context;
import android.content.res.TypedArray;
import android.util.AttributeSet;
import android.view.View;
public class Button extends View {
public class Button extends TextView {
public Button(Context context) {
super(context);
@@ -26,10 +25,14 @@ public class Button extends View {
public native final void native_setText(long widget, String text);
protected native void native_setOnClickListener(long widget, OnClickListener l);
@Override
public final void setText(CharSequence text) {
native_setText(widget, String.valueOf(text));
}
@Override
public void setTextSize(float size) {}
@Override
public void setOnClickListener(final OnClickListener l) {
native_setOnClickListener(widget, l);