title: How to change an image in a ListView, when the image is clicked?
body: <p><strong>EDIT: I've solved this issue, if interested, please take a look at my answer to see how I did it!</strong></p>
  
  <p>I am currently working in Android Studio. I have a ListView that I populate with several items. Within each of these items is an ImageButton that has a "+" as the image. What I want to do is, whenever that image is clicked (not the entire ListView item, just the image), I want that image of "+" to become another image. Any help would be appreciated, as this has been an ongoing issue for a while!</p>
  
  <p>Here is the current code that I attempt to use to achieve this:</p>
  
  <pre><code>final ImageButton movieSeen = (ImageButton convertView.findViewById(R.id.movieWatched);
          movieSeen.setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View v) {
                  movieSeen.setImageResource(R.drawable.ic_check_circle_black_24dp);
              }
          });
  </code></pre>
  
  <p>Currently this does update the image that I click correctly, BUT it also updates images that are not yet rendered on the screen, so when I scroll the list view down, other objects are also changed to ic_check_circle_black_24dp.</p>
  
  <p>What I want is pretty straightforward, I just don't know how to achieve it. I just want to click an ImageButton, that's inside an item on a ListView, and have that ImageButton change its image resource.</p>
  
  <p>Here is my custom array adapter as requested!</p>
  
  <pre><code>private class MovieScrollAdapter extends ArrayAdapter&lt;Movie&gt; {//custom array adapter
      private Context context;
      private List&lt;Movie&gt; movies;
  
      public MovieScrollAdapter(Context context, List&lt;Movie&gt; movies){
          super(context, -1, movies);
          this.context = context;
          this.movies = movies;
  
          if(this.movies.isEmpty()){//if no results were returned after all processing, display a toast letting the user know
              Toast.makeText(getApplicationContext(), R.string.no_matches, Toast.LENGTH_SHORT).show();
          }
      }
  
      @Override
      public View getView(final int position, View convertView, ViewGroup parent){
          if (convertView == null) {
              LayoutInflater inflater = (LayoutInflater) context.
                      getSystemService(Context.LAYOUT_INFLATER_SERVICE);
              convertView = inflater.inflate(R.layout.movie_layout, parent, false);
          }
  
          TextView title = (TextView) convertView.findViewById(R.id.title);
          title.setText(movies.get(position).getTitle());
  
          TextView plot = (TextView) convertView.findViewById(R.id.plot);
          plot.setText(movies.get(position).getPlot());
  
          TextView genre = (TextView) convertView.findViewById(R.id.genre);
          genre.setText(movies.get(position).getGenre());
  
  
          TextView metaScore = (TextView) convertView.findViewById(R.id.metascore);
  
          if(movies.get(position).getMetaScore() == -1){//if the metaScore is set to -1, that means movie has not been rated, which by inference means it is not yet released
              metaScore.setText(R.string.movie_not_released);
              metaScore.setTextSize(TypedValue.COMPLEX_UNIT_SP, 9.5f);//smaller text so it fits without breaking anything
              metaScore.setTextColor(getColor(R.color.colorAccent));
          } else {
              metaScore.setText("    " + Integer.valueOf(movies.get(position).getMetaScore()).toString() + " ");//using white space for minor formatting, instead of altering margins each time this is rendered
              metaScore.setTextSize(TypedValue.COMPLEX_UNIT_SP, 25);
  
              //setting up a "highlighted" background to achieve metacritic square effect
              Spannable spanText = Spannable.Factory.getInstance().newSpannable(metaScore.getText());
              spanText.setSpan(new BackgroundColorSpan(getColor(R.color.metaScore)), 3, 7, Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
              metaScore.setText(spanText);
              metaScore.setTextColor(getColor(android.R.color.primary_text_dark));
  
          }
  
          ImageView image = (ImageView) convertView.findViewById(R.id.imageView);
          new ImageDownloadTask((ImageView)image).executeOnExecutor(AsyncTask.THREAD_POOL_EXECUTOR, movies.get(position).getPosterURL());//because there are several images to load here, we let these threads run parallel
  
          title.setOnClickListener(new View.OnClickListener() {//setting up a simple onClickListener that will open a link leading to more info about the movie in question!
              @Override
              public void onClick(View v) {
                  Uri uri = Uri.parse(movies.get(position).getMovieURL());
                  Intent intent = new Intent(Intent.ACTION_VIEW, uri);
                  startActivity(intent);
              }
          });
  
          final ImageButton movieSeen = (ImageButton) convertView.findViewById(R.id.movieWatched);
          movieSeen.setOnClickListener(new View.OnClickListener() {
              @Override
              public void onClick(View v) {
                  movieSeen.setImageResource(R.drawable.ic_check_circle_black_24dp);
              }
          });
  
  
  
  
          return convertView;
      }
  
  }
  </code></pre>