diff --git a/app/src/main/java/com/example/vikramjeet/activities/ImageSearchActivity.java b/app/src/main/java/com/example/vikramjeet/activities/ImageSearchActivity.java index baa8161..ee7a788 100644 --- a/app/src/main/java/com/example/vikramjeet/activities/ImageSearchActivity.java +++ b/app/src/main/java/com/example/vikramjeet/activities/ImageSearchActivity.java @@ -14,7 +14,6 @@ import android.view.MenuItem; import android.view.View; import android.widget.AdapterView; -import android.widget.EditText; import com.etsy.android.grid.StaggeredGridView; import com.example.vikramjeet.adapters.ImageAdapter; @@ -37,7 +36,7 @@ public class ImageSearchActivity extends ActionBarActivity implements SettingsFilterDialog.SettingsFilterDialogListener { private final int REQUEST_CODE = 200; public static final String url = "https://ajax.googleapis.com/ajax/services/search/images?v=1.0&rsz=8&q="; - private EditText etQuery; +// private EditText etQuery; private StaggeredGridView gvResults; private ArrayList images; private ImageAdapter adapter; diff --git a/app/src/main/java/com/example/vikramjeet/helpers/EndlessScrollListener.java b/app/src/main/java/com/example/vikramjeet/helpers/EndlessScrollListener.java index dd2fc75..63eba4d 100644 --- a/app/src/main/java/com/example/vikramjeet/helpers/EndlessScrollListener.java +++ b/app/src/main/java/com/example/vikramjeet/helpers/EndlessScrollListener.java @@ -43,9 +43,9 @@ public void onScroll(AbsListView view,int firstVisibleItem,int visibleItemCount, if (totalItemCount < previousTotalItemCount) { this.currentPage = this.startingPageIndex; this.previousTotalItemCount = 0; - if (totalItemCount == 0) { +// if (totalItemCount == 8) { this.loading = true; - } +// } } // If it’s still loading, we check to see if the dataset count has // changed, if so we conclude it has finished loading and update the current page diff --git a/app/src/main/res/menu/menu_image_detail.xml b/app/src/main/res/menu/menu_image_detail.xml index c40f17c..b00b252 100644 --- a/app/src/main/res/menu/menu_image_detail.xml +++ b/app/src/main/res/menu/menu_image_detail.xml @@ -2,6 +2,11 @@ xmlns:app="http://schemas.android.com/apk/res-auto" xmlns:tools="http://schemas.android.com/tools" tools:context="com.example.vikramjeet.activities.ImageDetailActivity"> - + + + diff --git a/app/src/main/res/menu/menu_image_search.xml b/app/src/main/res/menu/menu_image_search.xml index 96e11e4..07ccf9a 100644 --- a/app/src/main/res/menu/menu_image_search.xml +++ b/app/src/main/res/menu/menu_image_search.xml @@ -9,14 +9,8 @@ app:showAsAction="ifRoom|collapseActionView" app:actionViewClass="android.support.v7.widget.SearchView" /> - -