mirror of
https://github.com/Pinball3D/Rabbit-R1.git
synced 2025-01-09 13:43:22 +00:00
56 lines
1.8 KiB
Java
56 lines
1.8 KiB
Java
|
package androidx.cursoradapter.widget;
|
||
|
|
||
|
import android.content.Context;
|
||
|
import android.database.Cursor;
|
||
|
import android.view.LayoutInflater;
|
||
|
import android.view.View;
|
||
|
import android.view.ViewGroup;
|
||
|
|
||
|
/* loaded from: classes.dex */
|
||
|
public abstract class ResourceCursorAdapter extends CursorAdapter {
|
||
|
private int mDropDownLayout;
|
||
|
private LayoutInflater mInflater;
|
||
|
private int mLayout;
|
||
|
|
||
|
public void setDropDownViewResource(int i) {
|
||
|
this.mDropDownLayout = i;
|
||
|
}
|
||
|
|
||
|
public void setViewResource(int i) {
|
||
|
this.mLayout = i;
|
||
|
}
|
||
|
|
||
|
@Deprecated
|
||
|
public ResourceCursorAdapter(Context context, int i, Cursor cursor) {
|
||
|
super(context, cursor);
|
||
|
this.mDropDownLayout = i;
|
||
|
this.mLayout = i;
|
||
|
this.mInflater = (LayoutInflater) context.getSystemService("layout_inflater");
|
||
|
}
|
||
|
|
||
|
@Deprecated
|
||
|
public ResourceCursorAdapter(Context context, int i, Cursor cursor, boolean z) {
|
||
|
super(context, cursor, z);
|
||
|
this.mDropDownLayout = i;
|
||
|
this.mLayout = i;
|
||
|
this.mInflater = (LayoutInflater) context.getSystemService("layout_inflater");
|
||
|
}
|
||
|
|
||
|
public ResourceCursorAdapter(Context context, int i, Cursor cursor, int i2) {
|
||
|
super(context, cursor, i2);
|
||
|
this.mDropDownLayout = i;
|
||
|
this.mLayout = i;
|
||
|
this.mInflater = (LayoutInflater) context.getSystemService("layout_inflater");
|
||
|
}
|
||
|
|
||
|
@Override // androidx.cursoradapter.widget.CursorAdapter
|
||
|
public View newView(Context context, Cursor cursor, ViewGroup viewGroup) {
|
||
|
return this.mInflater.inflate(this.mLayout, viewGroup, false);
|
||
|
}
|
||
|
|
||
|
@Override // androidx.cursoradapter.widget.CursorAdapter
|
||
|
public View newDropDownView(Context context, Cursor cursor, ViewGroup viewGroup) {
|
||
|
return this.mInflater.inflate(this.mDropDownLayout, viewGroup, false);
|
||
|
}
|
||
|
}
|