title: ListView addHeaderView causes position to increase by one?
body: <p>Below is a code snippet with a ListView. I added an emptyView and a headerView. Adding the headerView causes the position in the onItemClick to be increased by one.</p>
  
  <p>So without the headerView the first list element would have position 0, with the headerView the position of the first list element would be 1!</p>
  
  <p>This causes errors in my adapter, e.g. when calling getItem() and using some other methods, see below.
  Strange thing: In the getView() method of the adapter the first list element is requested with position 0 even if the headerView is added!!</p>
  
  <pre><code>public View onCreateView(LayoutInflater inflater, ViewGroup container, Bundle savedInstanceState) {
      ListView list = (ListView) viewSwitcher.findViewById(R.id.list);
      View emptyView = viewSwitcher.findViewById(R.id.empty);
      list.setEmptyView(emptyView);
  
      View sectionHeading = inflater.inflate(R.layout.heading, list, false);
      TextView sectionHeadingTextView = (TextView) sectionHeading.findViewById(R.id.headingText);
      sectionHeadingTextView.setText(headerText);
      list.addHeaderView(sectionHeading);
  
      list.setAdapter(listAdapter);
  
      list.setOnItemClickListener(new OnItemClickListener() {
  
          @Override
          public void onItemClick(AdapterView&lt;?&gt; parent, View view, int position, long id) {
              listAdapter.getItem(position);
              //Do something with it
          }
      });
  }
  </code></pre>
  
  <p>Some adapter methods:</p>
  
  <pre><code>@Override
  public int getViewTypeCount() {
      return TYPE_COUNT;
  }
  
  @Override
  public int getItemViewType(int position) {
      return (position &lt; items.size()) ? ITEM_NORMAL : ITEM_ADVANCED;
  }
  
      @Override
  public Product getItem(int position) {
      return items.get(position);
  }
  @Override
  public boolean areAllItemsEnabled() {
      return false;
  }
  
  @Override
  public boolean isEnabled(int position) {
      return (position &lt; items.size());
  }
  </code></pre>
  
  <p>Is this the normal behaviour when adding a headerView?? And how to overcome the issues in my adapter?</p>