Sample for Seesaw Android Project.
- Download the code.
- Open the code in Android Studio.
- Run the app.
- RecyclerView withe GridLayoutManager for displaying the images
- Constrain the images to be square using ConstraintLayout.
- Use Retrofit to query the Flickr API.
- GSON for parsing the JSON response into a custom Java object.
- Build the URL and use Glide to load the images into the RecyclerView
- Use a progress bar to show loading state together with Glide's RequestListener Interface.
- Save the instance state on rotation.
- Add a custom item at the end of the list which is used in BindViewHolder to load more items (the next page).
- Glide handles image performance and caching.
- Use the MediaStore content provider to save the image and make it available externally to other apps.
- Use a singleTop launch mode for the search activity to preserve the search when navigating back from the Detail view.
- When scrolling really quickly, sometimes Glide messes up the order of the items, and you have to scroll up and down to reorder correctly.
- No screen or feedback to show how many results left, and no informative error message if the API yields no results.
- No data persistence.
- Didn't check for backwards compat.
- SQLLite or SharedPreferences for persistence
- A lot of work could be done to make the UI more intuitive
- Better error handling (more informative to user)