0
IM試圖讓輸出FRM一個異步類,並在網格視圖使用側的片段 我敢肯定,我的輸入是正確的網適配器不工作
public void processFinish(movieList output) {
String[] movieId=output.getMovieId();
String[] movieImg=output.getMovieId();
boolean response=output.getStatus();
if(response==true){
GridView gridView = (GridView) view.findViewById(R.id.gridView_cover);
MovieAdapter = new movieGridAdapter(getActivity(), movieImg);
gridView.setAdapter(MovieAdapter);
}
GridAdapter
public View getView(int position, View view, ViewGroup viewGroup) {
ImageView imageView;
if(view==null){
imageView= new ImageView(mContext);
// imageView.setLayoutParams(new GridView.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT,ViewGroup.LayoutParams.MATCH_PARENT));
imageView.setScaleType(ImageView.ScaleType.FIT_XY);
}
else
{
imageView=(ImageView) view;
}
Picasso.with(mContext).load(image_base_url+imgs[position]).into(imageView);
//Log.v(movieGridAdapter.class.getSimpleName(),"http://image.tmdb.org/t/p/w500/"+imgs[position]);
return imageView;
}