Bug 895726 - Ensure valid filename when triggering Gallery view activity

Gallery will be in charge of maybe saving the file that we are passing.
If we pass it a file that has no extension, trying to save inside the
'pictures' DeviceStorage will fail because of the missing extension. So
we check if the filename has one and if it does not, we force one by
guessing from mime type.