1

hi i have a problem friends i am passing the text and the images from the Json using volley library and recycler view with horizontal orientation everything working fine but i am getting more gap in between the images because of that navigation drawer also effecting this the image of the home screen

Here is navigation drawer

This adapter featured products

public class FeaturedAdapter extends RecyclerView.Adapter<ViewHolder> {
ImageLoader imageLoader = AppController.getInstance().getImageLoader();
private Context context;
private List<Data> fpdata;

public FeaturedAdapter(Context context, List<Data> fpdata) {
    this.context = context;
    this.fpdata = fpdata;
}

@Override
public ViewHolder onCreateViewHolder(ViewGroup parent, int viewType) {
    View fpds = LayoutInflater.from(parent.getContext()).inflate(R.layout.singlefeatured, parent,false);
    ViewHolder viewHolder = new ViewHolder(fpds);
    return viewHolder;
}

@Override
public void onBindViewHolder(ViewHolder holder, int position) {
    Data feature=fpdata.get(position);

    holder.netfp.setImageUrl(feature.getFpimage(),imageLoader);
    holder.title.setText(feature.getTitle());
    holder.price.setText(feature.getPrice());
}

@Override
public int getItemCount() {
    return fpdata.size();
}
}
Syed Qasim Ahmed
  • 1,352
  • 13
  • 24
Ayub baba
  • 81
  • 9
  • http://stackoverflow.com/questions/24618829/how-to-add-dividers-and-spaces-between-items-in-recyclerview. You can use item decorators to specify spacing between items – Raghunandan Nov 24 '15 at 05:59
  • this looks more like a problem with your imageview properties. try `android:adjustViewBounds="true"` in your item layout on your imageview – David Medenjak Nov 27 '15 at 23:28

0 Answers0