create a downsampled version bm for the thumbnail preview
created a new function to save the bitmap
added a catch for out of memory exceptions for creating bitmaps