moves reading and writing recently used query words to async task, fixes a bug where duplicate images are shown, fixes a bug where past queries do not always show up, adds a spinner to indicate image loading