MizzleDK/Mizuu — pull request #480 by DavidWiesner (2014-12-03 05:41:45+00:00)
Title: Remove unnessesary refreshes in TvShowLibraryFragment

Hi Mitchell,

thanks for your great work and the awesome Material Design polish!

I saw that the `TvShowLibraryFragment` gets refreshed multiple times. You can see this by go to a detail view of an TvShow and press the Back-button from the `TvShowDetails`-Activity. All the images getting reloaded within their fade-in animation.

This is because `TvShowLibraryFragment.notifyDataSetChanged()` gets called multiple times.
In the `onResume()` method the `notifyDataSetChanged()` can be remove because you calling `forceLoaderLoad()` this results in an `AsyncTask` call in the `loaderCallbacks` where `showTvShowSection(0)` is called in the `onPostExecute()` method. And this will result in another `AsyncTask` call the `TvShowSectionLoader`. This will than call `sortTvShows()` on his `onPostExecute()`.

And any `sortTvShows()` call will call `sortBy()` and in the end this will call the final `notifyDataSetChanged()`.
And for the last reason i also removed all `notifyDataSetChanged()` that came after a `sortTvShows()` call.

It´s just a fine-tune pull request, but it results in a much nicer transformation when you press Back from the TvShowDetails`-Activity.

regards,
david