title: Android Pull-to-Refresh with ListView Fragment & Custom ListView Adapter
body: <p>I built my project using the Android Studio start options (Automatically builds the <code>action bar</code> with the tabs) so a bit is generated for me. I did however implement a <code>list-view fragment</code> for each one of the tabs that uses custom <code>adapters</code>. </p>
  
  <p>I'm having a trouble adding the pull-to-refresh lib from <a href="https://github.com/chrisbanes/ActionBar-PullToRefresh/wiki/QuickStart-ABC" rel="nofollow noreferrer">Chris Bane</a>. Maybe I'm importing it wrong? I'm fairly new at android development and especially with this new Gradle stuff.</p>
  
  <p>I'm Importing the github repository in the build.gradle file here:</p>
  
  <pre><code>apply plugin: 'android'
  
  android {
  compileSdkVersion 19
  buildToolsVersion "19.0.1"
  
  defaultConfig {
      minSdkVersion 14
      targetSdkVersion 19
      versionCode 1
      versionName "1.0"
  }
  buildTypes {
      release {
          runProguard false
          proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.txt'
      }
    }
  }
  dependencies {
     compile 'com.android.support:support-v4:19.0.1'
     compile 'com.android.support:appcompat-v7:19.0.1'
     compile 'com.github.chrisbanes.actionbarpulltorefresh:extra-abc:+'
   } 
  </code></pre>
  
  <p>Everything minus the minSDKVersion &amp; the last compile in dependencies was pre-generated when my project was created. This build.gradle file is the one in my `/app folder.</p>
  
  <p>Gradle will sync properly and I will see files from the actionbar git in my .idea folder in the project root.</p>
  
  <p><strong>Here is where I am getting confused:</strong></p>
  
  <p>In the github repo "quick start" it says </p>
  
  <blockquote>
    <p>The first thing you need to do is wrap your refreshable view in a PullToRefreshLayout:</p>
  </blockquote>
  
  <p>With a code example doing something like this:</p>
  
  <pre><code>&lt;uk.co.senab.actionbarpulltorefresh.extras.actionbarcompat.PullToRefreshLayout&gt;
  &lt;listview/&gt;
  &lt;/uk.co.senab.actionbarpulltorefresh.extras.actionbarcompat.PullToRefreshLayout&gt;
  </code></pre>
  
  <p>Is <code>uk.co.senab.actionbarpulltorefresh.extras</code> suppose to be my projects name, so <code>com.lucaapp.app</code>?</p>
  
  <p>Here is my XML for my ListFragment, where u'll see my confusion:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;
  
  &lt;com.lucaapp.app.PullToRefreshLayout xmlns:android="http://schemas.android.com/apk/res/android"
  android:orientation="vertical"
  android:layout_width="match_parent"
  android:layout_height="match_parent"
  android:id="@+id/ptr_layout" &gt;
  
  
  &lt;ListView
      android:id="@android:id/list"
      android:layout_width="match_parent"
      android:layout_height="match_parent"
      android:divider="#b5b5b5"
      android:dividerHeight="1dp"
      android:listSelector="@drawable/list_selector" /&gt;
  
  
  &lt;TextView
      android:id="@android:id/empty"
      android:layout_width="fill_parent"
      android:layout_height="fill_parent"
      android:text="No Events" /&gt;
  
  &lt;/com.lucaapp.app.PullToRefreshLayout&gt;
  </code></pre>
  
  <p>This will not give me any errors immediately until I try to implement the code from the <code>quick start guide</code> in my fragment class. I get an <code>Cannot Resolve Symbol</code> error trying to import that github repo methods.</p>
  
  <p>I've tried the following which makes the import red with <code>cannot resolve symbol</code> error:</p>
  
  <pre><code>import com.lucapp.app.PullToRefreshAttacher;
  import com.lucapp.app.PullToRefreshLayout;
  import uk.co.senab.actionbarpulltorefresh.extras.actionbarcompat.PullToRefreshAttacher;
  </code></pre>