react-native/Examples/UIExplorer/js
Connor McEwen 51efaab120 Handle "Never Ask Again" in permissions and add requestMultiplePermissions
Summary:
In order to get featured in the Google Play Store, we had to handle a few specific cases with permissions based on feedback from the editorial team.

First, which was previously possible with this permissions module was bumping the sdk to version 23.

The second is requesting multiple permissions at one time. In order for the camera + upload to work, we needed to request both camera permissions + media storage in one flow.

The last is handling the case where the user checks the "Never Ask Again" box. This will only appear after a user denies a permission once and is then prompted again. The logic for handling this case is taken from here: http://stackoverflow.com/questions/31928868/how-do-we-distinguish-never-asked-from-stop-asking-in-android-ms-runtime-permis/35495372#35495372

We were also seeing a few crashes similar to #10009 due to `onRequestPermissionsResult` being called before `onResume` (http://stackoverflow.com/questions/35205643/why-is-onresume-called-after-onrequestpermissionsresult), so I delaye
Closes https://github.com/facebook/react-native/pull/10221

Differential Revision: D4232551

fbshipit-source-id: fee698d1c48a2d86623cb87996f3d17f4c10a62e
2016-11-24 22:43:28 -08:00
..
AnimatedGratuitousApp Clean unused import modules. 2016-10-16 11:13:40 -07:00
NavigationExperimental Reverted commit D4027388 2016-10-16 04:13:42 -07:00
Navigator Kill require('image!...') 2016-11-22 21:13:52 -08:00
Thumbnails Cleanup UIExplorer folder 2016-07-12 05:59:13 -07:00
AccessibilityAndroidExample.android.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
AccessibilityIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
ActionSheetIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
ActivityIndicatorExample.js ActivityIndicator Example ES6 classes migration and TimerMixin removal 2016-08-02 17:13:30 -07:00
AdSupportIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
AlertExample.js Android: Implement cancelable option for Alerts 2016-08-09 06:13:48 -07:00
AlertIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
AnimatedExample.js
AppStateExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
AssetScaledImageExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
AsyncStorageExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
BorderExample.js
BoxShadowExample.js
ButtonExample.js Add disabled prop 2016-10-14 19:43:40 -07:00
CameraRollExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
CameraRollView.js Throw flow error when trying to access a style that is not defined on a stylesheet 2016-07-18 23:28:25 -07:00
ClipboardExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
DatePickerAndroidExample.js Android datepicker mode configurations added 2016-11-23 04:58:31 -08:00
DatePickerIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
ExampleTypes.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
GeolocationExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
ImageCapInsetsExample.js Kill require('image!...') 2016-11-22 21:13:52 -08:00
ImageEditingExample.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
ImageExample.js Cleanup before image! codemod 2016-11-22 21:13:52 -08:00
KeyboardAvoidingViewExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
LayoutAnimationExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
LayoutEventsExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
LayoutExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
LinkingExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
ListViewExample.js Fix minor typo in ListViewExample.js 2016-07-18 10:30:53 -07:00
ListViewGridLayoutExample.js
ListViewPagingExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
MapViewExample.js Use image references consistently in UIExplorer 2016-08-17 04:43:52 -07:00
ModalExample.js Fix ModalExample flex issue with Button 2016-10-28 05:43:35 -07:00
NativeAnimationsExample.js Add support for native animated events on iOS 2016-11-01 03:58:53 -07:00
NavigatorIOSColorsExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
NavigatorIOSExample.js Kill require('image!...') 2016-11-22 21:13:52 -08:00
NetInfoExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
OrientationChangeExample.js Listen to device orientation changes 2016-09-06 03:59:01 -07:00
PanResponderExample.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
PermissionsExampleAndroid.android.js Handle "Never Ask Again" in permissions and add requestMultiplePermissions 2016-11-24 22:43:28 -08:00
PickerExample.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
PickerIOSExample.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
PointerEventsExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
ProgressBarAndroidExample.android.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
ProgressViewIOSExample.js
PushNotificationIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
RCTRootViewIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
RTLExample.js Add viewConfig to RCTSlider Component, fix #10158 2016-10-12 08:59:05 -07:00
RefreshControlExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
RootViewSizeFlexibilityExampleApp.js
ScrollViewExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
ScrollViewSimpleExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
SegmentedControlIOSExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
SetPropertiesExampleApp.js
ShareExample.js Add Share module 2016-07-25 03:43:29 -07:00
SliderExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
SnapshotExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
StatusBarExample.js Add currentHeight constant to status bar docs 2016-11-05 17:13:29 -07:00
SwipeableListViewExample.js Remove react-native.js.flow 2016-09-14 02:58:40 -07:00
SwitchExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
TabBarIOSExample.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
TextExample.android.js Fix RN instrumentation tests 2016-09-26 11:58:35 -07:00
TextExample.ios.js Added support of `<Text>`'s `selectable` attribute on iOS 2016-11-17 16:13:28 -08:00
TextInputExample.android.js Cleanup: Prefer `React.Element` over `React$?Element` 2016-10-14 08:59:37 -07:00
TextInputExample.ios.js RN TextInput: don't let user more than maxLength when TextInput already exceeds it 2016-10-18 08:13:41 -07:00
TimePickerAndroidExample.js FIX #9939 - Add missing options argument to Android picker example 2016-09-16 00:43:30 -07:00
TimerExample.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
ToastAndroidExample.android.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
ToolbarAndroidExample.android.js Kill require('image!...') 2016-11-22 21:13:52 -08:00
TouchableExample.js Fix for TouchableNativeFeedback having Animated.Component direct child 2016-10-25 00:28:37 -07:00
TransformExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
TransparentHitTestExample.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
UIExplorerActions.js
UIExplorerApp.android.js Kill require('image!...') 2016-11-22 21:13:52 -08:00
UIExplorerApp.ios.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
UIExplorerBlock.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
UIExplorerButton.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
UIExplorerExampleContainer.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
UIExplorerExampleList.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
UIExplorerList.android.js Introduce Button Component 2016-10-10 17:28:39 -07:00
UIExplorerList.ios.js Introduce Button Component 2016-10-10 17:28:39 -07:00
UIExplorerNavigationReducer.js Cleanup UIExplorer folder 2016-07-12 05:59:13 -07:00
UIExplorerPage.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
UIExplorerSettingSwitchRow.js Add some stall stuff as settings to native animated example 2016-09-06 19:58:35 -07:00
UIExplorerStatePersister.js Deploy v0.35.0 2016-11-14 20:45:17 -08:00
UIExplorerStateTitleMap.js
UIExplorerTitle.js Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
URIActionMap.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
VibrationExample.js Ios: complete iOS vibration pattern supports (js) 2016-08-25 18:28:38 -07:00
VibrationIOSExample.js
ViewExample.js Reinstate view example for screenshot tests 2016-08-16 04:58:30 -07:00
ViewPagerAndroidExample.android.js Modify image url from http to https on examples 2016-11-03 08:13:37 -07:00
WebSocketExample.js Android WebSocket: include cookies in request 2016-11-07 10:43:44 -08:00
WebViewExample.js Implement a postMessage function and an onMessage event for webviews … 2016-10-16 06:43:46 -07:00
XHRExample.android.js
XHRExample.ios.js Support RCTNetworking#clearCookies on iOS 2016-08-26 05:43:39 -07:00
XHRExampleCookies.js
XHRExampleFetch.js Update XHRExampleFetch and dump the response headers 2016-09-06 04:28:38 -07:00
XHRExampleHeaders.js
XHRExampleOnTimeOut.js Cleanup UIExplorer folder 2016-07-12 05:59:13 -07:00
bunny.png
createExamplePage.js Clean unused import modules. 2016-10-16 11:13:40 -07:00
flux@3x.png
hawk.png
helloworld.html
http_test_server.js Android WebSocket: include cookies in request 2016-11-07 10:43:44 -08:00
messagingtest.html Implement a postMessage function and an onMessage event for webviews … 2016-10-16 06:43:46 -07:00
relay@3x.png
slider-left.png
slider-left@2x.png
slider-right.png
slider-right@2x.png
slider.png
slider@2x.png
uie_comment_highlighted@2x.png
uie_comment_normal@2x.png Cleanup UIExplorer folder 2016-07-12 05:59:13 -07:00
uie_thumb_big.png
uie_thumb_normal@2x.png
uie_thumb_selected@2x.png
websocket_test_server.js Android WebSocket: include cookies in request 2016-11-07 10:43:44 -08:00