From a101b528efdee74fc1970b7f1fe68263f0b20269 Mon Sep 17 00:00:00 2001 From: Allan Wang Date: Fri, 18 Aug 2017 14:39:40 -0700 Subject: Create media picker action items (#40) * Create action items * Increment version * Update camera action * Abstract camera action * Add and test * Refactor and add docs --- mediapicker/README.md | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'mediapicker/README.md') diff --git a/mediapicker/README.md b/mediapicker/README.md index a743a47..0eb6fd5 100644 --- a/mediapicker/README.md +++ b/mediapicker/README.md @@ -40,4 +40,23 @@ Note that this launches the activity through a `startActivityForResult` call You may get the activity response by overriding your `onActivityResult` method to first verify that the request code matches and then call `kauOnMediaPickerResult`, -which will return the list of MediaModels. \ No newline at end of file +which will return the list of MediaModels. + +## MediaActions + +On top of retrieving your media file, you may also add action items to the start +of the grid. All actions will return their results immediately, and retrieve media types based on the activity. + +### MediaActionCamera + +Gets an image or a video from the default camera. No permissions are necessary. +Note that since api 24, passing general uris may throw a [FileUriExposedException](https://developer.android.com/reference/android/os/FileUriExposedException.html), +so your own resolvers need to be passed for this to work. See the sample xml folder for an example. + +### MediaActionCameraVideo + +Given that getting videos do not require resolvers, this item can be used for videos only without any required arguments. + +### MediaActionGallery + +Defines whether you want to pick one or more media items from the default gallery app. \ No newline at end of file -- cgit v1.2.3