Added all handling of photo and video capture as well as choosing from the gallery.