Moved list fragment logic into behaviour classes

Refactored the code so that the list fragment is now generic, and takes
in a behavior class that encapsulates the data that should be shown by
the fragment and a input stream handler to handle the parsing of the new
data.