react-native/Libraries/Components
Martin Konicek ad8cbb6dea Support ScrollView.scrollToEnd on Android natively
Summary:
This is a followup for https://github.com/facebook/react-native/pull/12088 and implements the scrolling to end on Android natively rather than sending a large scroll offset from JS.

This turned out to be an OK amount of code, and some reduction in the amount of JavaScript. The only part I'm not particularly happy about is:

```
// ScrollView always has one child - the scrollable area
int bottom = scrollView.getChildAt(0).getHeight() + scrollView.getPaddingBottom();
```

According to multiple sources (e.g. [this SO answer](http://stackoverflow.com/questions/3609297/android-total-height-of-scrollview)) it is the way to get the total size of the scrollable area, similar to`scrollView.contentSize` on iOS but more ugly and relying on the fact the ScrollView always has a single child (hopefully this won't change in future versions of Android).

An alternative is:

```
View lastChild = scrollLayout.getChildAt(scrollLayout.getChildCount() - 1);
int bottom = lastChild.getBottom() + scrollLayout.getPadd
Closes https://github.com/facebook/react-native/pull/12101

Differential Revision: D4481523

Pulled By: mkonicek

fbshipit-source-id: 8c7967a0b9e06890c1e1ea70ad573c6eceb03daf
2017-01-30 10:28:32 -08:00
..
ActivityIndicator RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
AppleTV Apple TV support 4: support for input (tvOS focus engine) 2016-12-19 06:28:40 -08:00
Clipboard Remove deprecated APIs and modules 2016-10-11 07:43:52 -07:00
DatePicker Stop other views from stealing the responder from PickerIOS and DatePickerIOS 2016-11-07 18:13:53 -08:00
DatePickerAndroid Android datepicker mode configurations added 2016-11-23 04:58:31 -08:00
DrawerAndroid RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
Keyboard relativeKeyboardHeight works wrong in some cases 2016-11-14 11:58:58 -08:00
MapView Add in support for showing annotation callouts by default without the user clicking on the pins 2016-11-20 00:58:28 -08:00
Navigation Apple TV support 4: support for input (tvOS focus engine) 2016-12-19 06:28:40 -08:00
Picker Fix iOS Picker Item Colors 2016-12-03 18:58:29 -08:00
ProgressBarAndroid RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
ProgressViewIOS RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
RefreshControl Add some `Fake`s for easier interaction snapshot testing 2016-12-20 15:58:30 -08:00
ScrollView Support ScrollView.scrollToEnd on Android natively 2017-01-30 10:28:32 -08:00
SegmentedControlIOS RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
Slider RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
StatusBar Revert D4450924: Expose StatusBar height on iOS 2017-01-25 17:59:30 -08:00
Switch RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
TabBarIOS Apple TV support 4: support for input (tvOS focus engine) 2016-12-19 06:28:40 -08:00
TextInput Guard against empy _inputRef in TextInput 2017-01-20 16:43:42 -08:00
TimePickerAndroid Clean unused import modules. 2016-10-16 11:13:40 -07:00
ToastAndroid Add very basic usage example for android toast 2016-09-19 06:43:54 -07:00
ToolbarAndroid RN: Update React (2/2) 2016-11-04 05:43:44 -07:00
Touchable fix Touchables inspector 2016-12-22 16:28:34 -08:00
UnimplementedViews Convert from React.createClass to ES6 classes 2016-07-26 01:13:31 -07:00
View Require `fbjs/lib/invariant` instead of `invariant` 2017-01-25 10:43:55 -08:00
ViewPager RN: Stop Deep Linking `ReactElement` 2016-10-14 18:59:10 -07:00
WebView Add a injectJavaScript method to the WebView component 2017-01-06 20:29:02 -08:00
Button.js Add testID prop to Button component 2017-01-09 02:43:35 -08:00
LazyRenderer.js Cleanup: Prefer `React.Element` over `React$?Element` 2016-10-14 08:59:37 -07:00
ScrollResponder.js Support ScrollView.scrollToEnd on Android natively 2017-01-30 10:28:32 -08:00
StaticContainer.js RN: Change `onlyChild => React.Children.only` 2016-10-14 18:59:10 -07:00
StaticRenderer.js Reverted commit D4027388 2016-10-16 04:13:42 -07:00
Subscribable.js