title: ListView filled from AsyncTask doesn't render
body: <p>I have a <code>Task</code> which extends Androids <code>AsyncTask</code> in order to get data from my Database in the cloud. I am doing this as to avoid <code>NetworkingOnMainThread</code> exception (I know you can set up <code>StrictMode</code> but in my opionion it's more of a hack than a solution).</p>
  
  <p>I get no errors whatsoever. I have checked values in debugging and everything gets fetched correctly from my database. I have a <code>Venue</code> where I set my name, description, image etc... and the <code>ArrayList&lt;Venue&gt;</code> which I use for my adapter gets instantiated properly.</p>
  
  <p>The problem is - the ListView doesn't render.</p>
  
  <p>Here is my custom adapter code</p>
  
  <pre><code>public class EventListArrayAdapter extends ArrayAdapter&lt;String&gt; {
  Context context;
  ArrayList&lt;Venue&gt; values;
  
  public EventListArrayAdapter(Context context, ArrayList&lt;Venue&gt; values) {
      super(context, R.layout.single_event_list_item);
      this.context = context;
      this.values = values;
  }
  
  public View getView(int position, View convertView, ViewGroup parent){
      View v = convertView;
  
      if(v==null){
          LayoutInflater inflater = (LayoutInflater) context.getSystemService(Context.LAYOUT_INFLATER_SERVICE);
          v = inflater.inflate(R.layout.single_event_list_item, null);
      }
  
      Venue currEvent = values.get(position);
  
      if(currEvent!=null){
          TextView singleItemTitle = (TextView) v.findViewById(R.id.singleItemTitle);
          TextView singleItemLocation = (TextView) v.findViewById(R.id.singleItemLocation);
          TextView singleItemDate = (TextView) v.findViewById(R.id.singleItemDate);
          ImageView singleItemImage = (ImageView) v.findViewById(R.id.singleItemImage);
  
          singleItemTitle.setText(currEvent.getName());
          singleItemDate.setText(currEvent.getDate());
          singleItemLocation.setText(currEvent.getLocation());
          singleItemImage.setImageBitmap(currEvent.getVenueImage());
      }
      return v;
  }
  
  }
  </code></pre>
  
  <p>And here is my <code>AsyncTask</code> code</p>
  
  <pre><code>private class FillContentTask extends AsyncTask&lt;String, Void, Void&gt; {
      ArrayList&lt;Venue&gt; venues;
      Context activity;
      ProgressDialog dialog;
  
      public FillContentTask(Context context) {
          this.activity = context;
      }
  
      @Override
      protected void onPreExecute() {
          dialog = new ProgressDialog(activity);
          dialog.setTitle("Loading...");
          dialog.show();
      }
  
      @Override
      protected Void doInBackground(String... params) {
          this.venues = Venue.getAll();
          for (Venue currentVenue : this.venues) {
              try {
                  InputStream in = new java.net.URL(currentVenue.getImageURL()).openStream();
                  currentVenue.setVenueImage(BitmapFactory.decodeStream(in));
              } catch (Exception e) {
                  Log.e("Error", e.getMessage());
                  e.printStackTrace();
              }
          }
          return null;
      }
  
      @Override
      protected void onPostExecute(Void result) {
          ListView list = (ListView) findViewById(R.id.eventList);
          EventListArrayAdapter adapter = new EventListArrayAdapter(activity, this.venues);
          list.setAdapter(adapter);
          dialog.hide();
      }
  }
  </code></pre>
  
  <p>And as I already said. To the best of my knowledge, the AsnycTask does it's job properly since all <code>ArrayList&lt;Venue&gt; values</code> get filled properly</p>