fyf před 1 rokem
rodič
revize
d7201ffa1f
2 změnil soubory, kde provedl 2 přidání a 2 odebrání
  1. +1
    -1
      app/src/main/java/com/example/bpa/view/adapter/wl_adapter.java
  2. +1
    -1
      app/src/main/java/com/example/bpa/view/from/wlgl_activity.java

+ 1
- 1
app/src/main/java/com/example/bpa/view/adapter/wl_adapter.java Zobrazit soubor

@@ -21,7 +21,7 @@ public class wl_adapter extends ArrayAdapter<BPA_MATERIAL> {
@NonNull
@Override
public View getView(int position, @Nullable View convertView, @NonNull ViewGroup parent) {
BPA_MATERIAL data = (BPA_MATERIAL) getItem(position);//得到当前项的 Fruit 实例
BPA_MATERIAL data = (BPA_MATERIAL) getItem(position);//得到当前项选中item实例
//为每一个子项加载设定的布局
View view = LayoutInflater.from(getContext()).inflate(R.layout.wl_item, parent, false);
//分别获取 image view 和 textview 的实例


+ 1
- 1
app/src/main/java/com/example/bpa/view/from/wlgl_activity.java Zobrazit soubor

@@ -98,7 +98,7 @@ public class wlgl_activity extends AppCompatActivity implements View.OnClickList
{
try{
bpa_materials= QueryDB.GetMaterialALL();
wl_adapter adapter = new wl_adapter(this, R.layout.wl_item, bpa_materials);
wl_adapter adapter = new wl_adapter(wlgl_activity.this, R.layout.wl_item, bpa_materials);
datatab.setAdapter(adapter);
}catch(Exception e){



Načítá se…
Zrušit
Uložit