Commit Graph

6621 Commits

Author SHA1 Message Date
Fred Liu 381a0051c7 Swipeables documentation
Summary: So users can know how to use

Reviewed By: hedgerwang

Differential Revision: D3399028

fbshipit-source-id: 5ce97c5464f1975145aba1bcf4b79550394859ae
2016-06-07 11:58:38 -07:00
Olivier Notteghem 837aafde72 Fix touch handling crash that can when Modal is displayed as a result of touch handling code
Reviewed By: dmmiller

Differential Revision: D3399325

fbshipit-source-id: 0a0bb179ef524bf35cc137d94ea3d5680a68aab2
2016-06-07 11:58:38 -07:00
Alex Kotliarskyi f3fab5184e Remove SourceCode.getScriptText
Summary:
After cleaning up JS SourceMap code, these native methods are not needed anymore.

On iOS it saves another 30+ Mb during development.

Reviewed By: javache, astreet

Differential Revision: D3348975

fbshipit-source-id: a68ae9b00b4dbaa374b421029ae676fc69ae5a75
2016-06-07 11:13:32 -07:00
Siqi Liu a7404713a4 Followup for Intercepting all redboxes in Android Ads Manager
Reviewed By: mkonicek

Differential Revision: D3398979

fbshipit-source-id: 9ea9ba6d45daf01284717a9eb889c16607109683
2016-06-07 10:58:23 -07:00
Siqi Liu 4b19db3159 Remove the Profiler Option in RN Android Dev Menu
Summary:
Remove the "Start/Stop" option in RN Android dev menu.

mkonicek talked to Mike Armstrong who originally added this option and he said Traceview didn't end up being used much and Systrace was the preferred way to do profiling, which is used from the command line.

Haven't removed all the codes behind because there are some codes in JNI, including native methods in C++ through the ReactBridge.

Dev menu before:
{F61306550}

Dev menu after:
{F61306553}

Reviewed By: mkonicek

Differential Revision: D3391092

fbshipit-source-id: c400d8bb3c196afa9ef53cda13476e1fec6c2384
2016-06-07 09:58:22 -07:00
Saurabh Aggarwal 7e7abff55a 4.5 / N [RNFeed] Isolate reusable util methods out of NetworkingModule
Reviewed By: lexs

Differential Revision: D3394808

fbshipit-source-id: 19c916be693377651f2c8e21eb3dd490ec68f74c
2016-06-07 09:43:31 -07:00
Andy Street 49a5fe493e Fix deletion layout animations to work with custom view managers
Summary: D3352450 didn't handle the case where removeClippedSubviews is on and the indices within the parent view don't match the indices JS is working on

Differential Revision: D3398675

fbshipit-source-id: 0a1b9cf41b02f71f6585db92474e4699b944d273
2016-06-07 09:43:31 -07:00
Fred Liu 4868948175 NUX-y bounce
Summary: On mount, bounce the 1st row so users know it's swipeable.

Reviewed By: fkgozali

Differential Revision: D3395214

fbshipit-source-id: 6d391209014a6a7957a2160734d8ef6548b7693b
2016-06-07 09:13:21 -07:00
Nick Lockwood 79dcbc7b29 Fix unit tests
Reviewed By: bestander

Differential Revision: D3398431

fbshipit-source-id: 37561bea78c933673595625530cf083c85c3fbbd
2016-06-07 08:43:22 -07:00
Valentin Agachi 282df0ed07 Remove extra packager call from objc-test
Reviewed By: bestander

Differential Revision: D3398448

fbshipit-source-id: dd0676021eac7169e55e7049d3edac6ee0c8bf45
2016-06-07 08:13:19 -07:00
Nick Lockwood 8b78846a95 Open sourced KeyboardAvoidingView
Summary:
KeyboardAvoidingView is a component we built internally to solve the common problem of views that need to move out of the way of the virtual keyboard.

KeyboardAvoidingView can automatically adjust either its position or bottom padding based on the position of the keyboard.

Reviewed By: javache

Differential Revision: D3398238

fbshipit-source-id: 493f2d2dec76667996250c011a1c5b7a14f245eb
2016-06-07 07:43:49 -07:00
Nick Lockwood d64368b9e2 Implement CSS z-index for iOS
Summary:
This diff implement the CSS z-index for React Native iOS views. We've had numerous pull request for this feature, but they've all attempted to use the `layer.zPosition` property, which is problematic for two reasons:

1. zPosition only affects rendering order, not event processing order. Views with a higher zPosition will appear in front of others in the hierarchy, but won't be the first to receive touch events, and may be blocked by views that are visually behind them.
2. when using a perspective transform matrix, views with a nonzero zPosition will be rendered in a different position due to parallax, which probably isn't desirable.

See https://github.com/facebook/react-native/pull/7825 for further discussion of this problem.

So instead of using `layer.zPosition`, I've implemented this by actually adjusting the order of the subviews within their parent based on the zIndex. This can't be done on the JS side because it would affect layout, which is order-dependent, so I'm doing it inside the view itself.

It works as follows:

1. The `reactSubviews` array is set, whose order matches the order of the JS components and shadowView components, as specified by the UIManager.
2. `didUpdateReactSubviews` is called, which in turn calls `sortedSubviews` (which lazily generates a sorted array of  `reactSubviews` by zIndex) and inserts the result into the view.
3.  If a subview is added or removed, or the zIndex of any subview is changed, the previous `sortedSubviews` array is cleared and  `didUpdateReactSubviews` is called again.

To demonstrate it working, I've modified the UIExplorer example from https://github.com/facebook/react-native/pull/7825

Reviewed By: javache

Differential Revision: D3365717

fbshipit-source-id: b34aa8bfad577bce023f8af5414f9b974aafd8aa
2016-06-07 07:43:49 -07:00
Nathan Azaria 993a928833 Fixed MapView's draggable annotation
Reviewed By: javache

Differential Revision: D3384947

fbshipit-source-id: 801a0998c8db788a731d27ae5956193ff23aa198
2016-06-07 07:28:27 -07:00
Siqi Liu 4959b21290 Enable Double R shortcut to reload JS when redbox is shown on Android
Summary: Make "double tap R" shortcut enabled when redbox is shown in RN Android, consistent with that in iOS.

Reviewed By: mkonicek

Differential Revision: D3390132

fbshipit-source-id: 48fc40c2ba371a34abcac42a077359d11e907dfc
2016-06-07 06:58:29 -07:00
Nick Lockwood 748a507861 Simplified Image.js
Summary:
Now that we no longer have a separate NetworkImageView implementation, we can remove that code path from Image.js

I've also moved the prefetch method into RCTImageViewManager for consistency with the getImageSize method, which means we no longer need to export the RCTImageLoader module to js.

Reviewed By: javache

Differential Revision: D3398157

fbshipit-source-id: fbbcf90a61549831ad28bad0cb3b50c375aae32c
2016-06-07 05:43:28 -07:00
Konstantin Raev 592d5fb8f3 Changed version of React dependency to ~
Summary:
React has some internal code related only to React Native.
Some times React needs to update them which will result in a breaking change for React Native but it would not be a breaking change for React public API, so no major version bump will happen.
It means that a non breaking API bump may result in a break for React Native.
That is why React Native should not depend on a ^ of React version.

However React is a peer dependency to React Native and we want to give some flexibility to users to update React independently, so we don't fix the version strict and use ~ to allow patches.

This will be fixed once we extract RN specific code from React into an independent dependency.

Reviewed By: avaly

Differential Revision: D3398202

fbshipit-source-id: cca520f4b80c9ed5ae6fb1444f3d0bf7ffb9c9dd
2016-06-07 04:43:30 -07:00
hlynurf 46c3af9941 Add Dohop to showcase
Summary:
Just released on Play Store and iOS has been in production since November.
Closes https://github.com/facebook/react-native/pull/7874

Differential Revision: D3397811

fbshipit-source-id: 3ed293c1baff59c9171814ed7d34402beb30b383
2016-06-07 02:58:33 -07:00
Konstantin Raev d836e8c0ef Reverted commit D3374937
Reviewed By: mhorowitz

Differential Revision: D3374937

fbshipit-source-id: e794fb9b8cb1194133da64dcb38861477406c307
2016-06-07 02:58:33 -07:00
邓国梁 2c59dca7b6 no need both iOSLink and AndroidLink
Summary:
**motivation**

if users showcase data only have `linkAppStore` or `linkPlayStore` , not both. They will be render as a not link block. like `D.I.T.` or `烘焙帮`

**Test plan**

Befor:

![2016-06-07 2 03 27](https://cloud.githubusercontent.com/assets/73235/15847463/a9c5922c-2cb8-11e6-902e-32a942d4f1bd.png)

After:

![2016-06-07 2 03 15](https://cloud.githubusercontent.com/assets/73235/15847467/b039df50-2cb8-11e6-893c-7cc25d876a5c.png)
Closes https://github.com/facebook/react-native/pull/7966

Differential Revision: D3398002

fbshipit-source-id: 4c9cbbe34fbda5d84a7165415c67559191b08b25
2016-06-07 02:13:39 -07:00
Sreejumon 7742900931 Fix the WebSocket sendBinary error
Summary:
Fixing the WebSocket SendBinary method error. This is a regression caused during recent change.
Closes https://github.com/facebook/react-native/pull/7956

Differential Revision: D3398065

fbshipit-source-id: 5d56eba807b59d1f3265cba5d5f501d610afebf2
2016-06-07 01:58:24 -07:00
Nick Lockwood 46c02b6ae5 Refactored subview management
Summary:
This diff refactors the view update process into two stages:

1. The `reactSubviews` array is set, whose order matches the order of the JS components and shadowView components, as specified by the UIManager.
2. The `didUpdateReactSubviews` method is called, which actually inserts the reactSubviews into the view hierarchy.

This simplifies a lot of the hacks we had for special-case treatment of subviews: In many cases we don't want to actually insert `reactSubviews` into the parentView, and we had a bunch of component-specific solutions for that (typically overriding all of the reactSubviews methods to store views in an array). Now, we can simply override the `didUpdateReactSubviews` method for those views to do nothing, or do something different.

Reviewed By: wwjholmes

Differential Revision: D3396594

fbshipit-source-id: 92fc56fd31db0cfc66aac3d1634a4d4ae3903085
2016-06-07 00:14:39 -07:00
Nicolas Charpentier 2a92b52ac8 Add Fresco to ProGuard
Summary:
Motivation #7760
Closes https://github.com/facebook/react-native/pull/7781

Differential Revision: D3397772

fbshipit-source-id: 02b6fd4a403da590fd1c55c554eca00e15899a03
2016-06-06 22:58:42 -07:00
Steve Mao edfe2a3a06 Fix how react is imported
Summary:
Thanks for submitting a pull request! Please provide enough information so that others can review your pull request:

(You can skip this if you're fixing a typo or adding an app to the Showcase.)

Explain the **motivation** for making this change. What existing problem does the pull request solve?

Prefer **small pull requests**. These are much easier to review and more likely to get merged. Make sure the PR does only one thing, otherwise please split it.

**Test plan (required)**

Demonstrate the code is solid. Example: The exact commands you ran and their output, screenshots / videos if the pull request changes UI.

Make sure tests pass on both Travis and Circle CI.

**Code formatting**

Look around. Match the style of the rest of the codebase. See also the simple [style guide](https://github.com/facebook/react-native/blob/master/CONTRIBUTING.md#style-guide).

For more info, see the ["Pull Requests" section of our "Contributing" guidelines](https://github.com/facebook/react-native/blob/mas
Closes https://github.com/facebook/react-native/pull/7962

Differential Revision: D3397289

fbshipit-source-id: 21adf955af4a623f1ce71e7a5e412020ceaad12a
2016-06-06 19:28:27 -07:00
Philipp von Weitershausen 588f01e998 Packager: accept relative --transformer paths everywhere.
Summary:
`react-native start` already ensures that the `--transformer` path is understood to be relative to CWD, not to the module that ends up importing that file. `react-native bundle` and `react-native dependencies` didn't up until this point.

**Test plan:** Ensured that `react-native bundle ... --transformer ./relative/path` works with this patch applied.
Closes https://github.com/facebook/react-native/pull/7857

Differential Revision: D3393777

fbshipit-source-id: 303a226fae9c8087c3dd3b2e8d004462ca66665e
2016-06-06 17:58:25 -07:00
Nick Lockwood 93c7a93de9 Reverted commit D3392214
Reviewed By: javache

Differential Revision: D3392214

fbshipit-source-id: 4136c8b0eb160f4b245df2e4b5d67d00efd7b1a7
2016-06-06 16:28:21 -07:00
Spencer Ahrens e79f5d7e7a add StyleSheet.absoluteFill convenience constant
Summary:
It's annoying and inefficient to create styles like

```
  wrapper: {
    position: 'absolute',
    left: 0,
    right: 0,
    top: 0,
    bottom: 0,
  },
```

all the time, so this makes a handy constant for reuse and a helper method to create customized
styles.

Reviewed By: devknoll

Differential Revision: D3389612

fbshipit-source-id: 88fbe9e8ca32a0bc937bf275cf5ae0739ee21302
2016-06-06 16:13:42 -07:00
Chris Hopman bf010a4c17 Invert native dependency of new bridge -> old bridge
Reviewed By: mhorowitz

Differential Revision: D3374937

fbshipit-source-id: 58b082bba727e33a3b08361be3630d669fc8dc5b
2016-06-06 16:13:41 -07:00
Fred Liu 26a92220c2 Allow some right swipe
Summary: Allow some right swipe so users know swiping is a possibility, with some bounceback.

Reviewed By: fkgozali

Differential Revision: D3388836

fbshipit-source-id: 596a6be3c641ff0ee6ac32d7c0d798478edef72b
2016-06-06 14:58:59 -07:00
Kishan Patel 7cd8591734 Fixed Typo: "Termimal" => "Terminal"
Summary:
Thanks for submitting a pull request! Please provide enough information so that others can review your pull request:

(You can skip this if you're fixing a typo or adding an app to the Showcase.)

Explain the **motivation** for making this change. What existing problem does the pull request solve?

Prefer **small pull requests**. These are much easier to review and more likely to get merged. Make sure the PR does only one thing, otherwise please split it.

**Test plan (required)**

Demonstrate the code is solid. Example: The exact commands you ran and their output, screenshots / videos if the pull request changes UI.

Make sure tests pass on both Travis and Circle CI.

**Code formatting**

Look around. Match the style of the rest of the codebase. See also the simple [style guide](https://github.com/facebook/react-native/blob/master/CONTRIBUTING.md#style-guide).

For more info, see the ["Pull Requests" section of our "Contributing" guidelines](https://github.com/facebook/react-native/blob/mas
Closes https://github.com/facebook/react-native/pull/7951

Differential Revision: D3394509

Pulled By: JoelMarcey

fbshipit-source-id: 0ae23950c69ae06a4b85d2e4b577a71e9aa2b7f4
2016-06-06 14:28:26 -07:00
Geoff Lawson 2fd537c55d Incorrect import reference of emptyFunction causes error when importi…
Summary:
Experimental component SwipeableListView fails to import due to incorrect import reference.  Followed example use of import of emptyFunction found in https://github.com/facebook/react-native/blob/master/Libraries/Components/TextInput/TextInput.js#L31
Closes https://github.com/facebook/react-native/pull/7954

Differential Revision: D3394202

fbshipit-source-id: db8ddc9d9635878f0ce1fb969ef6c6e3c27d63f3
2016-06-06 13:58:24 -07:00
Hedger Wang 2e7a536aba Unbreak Image.ios.js
Summary: Don't pass `null` as default empty uri. Use `undefined` instead.

Differential Revision: D3393211

fbshipit-source-id: ac7cd385aa7f2196bc0743b8679dd2c94be4108b
2016-06-06 13:23:30 -07:00
Sokovikov 8d038572f3 show stacktrace in yellowbox
Summary:
instead of #7030

<img src="https://cloud.githubusercontent.com/assets/1488195/15109209/f31dbbbc-15e2-11e6-80b0-99aeea7eb630.gif"" width="300" />
Closes https://github.com/facebook/react-native/pull/7459

Differential Revision: D3282147

Pulled By: frantic

fbshipit-source-id: cd79b729685047c303945e83d0672ca1671e2cca
2016-06-06 12:58:37 -07:00
Ben Nham 1fce89176b Explicitly set default background color in RCTTextView
Summary:
RCTShadowText currently explicitly defaults to black text color:

https://github.com/facebook/react-native/blob/d46ac11/Libraries/Text/RCTShadowText.m#L204

However, the UITextView used by RCTTextInput doesn't explicitly default to black text color.

This causes issues when RCTTextInput is in rich text editing mode (i.e. when the <TextInput> element uses child <Text> nodes to provide extra styling info) and the client doesn't provide us with any explicit color info. In this case, the following series of badness occurs:

1. -[UITextView attributedText] will return an attributed string without the NSColor property set.
2. -[RCTShadowText attributedString] will return an attributed string with NSColor equal to blackColor.
3. The `[_textView.attributedText isEqualToAttributedString:_pendingAttributedText]` check in -performPendingTextUpdate will fail and causes -[UITextView setText:] to be called.
4. -setText: clears the marked text range in the text view, which breaks multi-character autocomplete (e.g. QWERTY input methods for CJK languages).

The easiest fix for now is to just make sure RCTUITextView and RCTShadowText default to the same text color.

Reviewed By: nicklockwood

Differential Revision: D3368726

fbshipit-source-id: a92cb188c60bac80d963af6b1f2a09f27ae084f5
2016-06-06 12:58:37 -07:00
Alexander Blom bc7ec03670 Add better markers for getConfig
Reviewed By: astreet

Differential Revision: D3358278

fbshipit-source-id: 16668cd33a42a120c2de88be4cb4a1c8d0d5a13c
2016-06-06 11:58:32 -07:00
Hedger Wang 1dc33b5f23 Add example for composite navigation.
Reviewed By: hramos

Differential Revision: D3388314

fbshipit-source-id: 7066363e03534e75ccdf8806db9ed395ee2163a4
2016-06-06 11:28:20 -07:00
Alexey Lang 42a5568419 Change API for using custom JSC
Reviewed By: javache

Differential Revision: D3392219

fbshipit-source-id: ae372dfe9ceab7f7c2da69c731515a05eb3b020a
2016-06-06 11:13:22 -07:00
Nick Lockwood 44c9cf3a91 Refactored subview management
Reviewed By: javache

Differential Revision: D3392214

fbshipit-source-id: 6f16841df5cf866dda5ac27dd244e266ec85a86e
2016-06-06 10:28:33 -07:00
Tom Walters 4e3a8343b3 Convert warning about keystore into warning block in SignedAPKAndroid.md
Summary:
The current docs page [Generating a Signed APK](https://facebook.github.io/react-native/docs/signed-apk-android.html) contains a note about keeping your generated keystore safe, but this isn't well highlighted.

This commit highlights the notice in a warning blockquote to ensure people following the guide don't miss the importance of keeping the keystore safe as shown below:

<img width="666" alt="screen shot 2016-06-06 at 10 01 25" src="https://cloud.githubusercontent.com/assets/1863808/15817245/10e4e6d2-2bcf-11e6-9fe8-defc8a6ec93c.png">
Closes https://github.com/facebook/react-native/pull/7948

Differential Revision: D3393005

fbshipit-source-id: e9c2666a79134eccc1b1868fe850ee896e63266e
2016-06-06 10:28:33 -07:00
Dave Miller f3507f99f1 Remove support for password property and only use secureTextEntry
Summary:
Reduce the public surface area of TextInput.  It only exposes a secureTextEntry property, but on Android was also accepting password as a prop.
This removes that.

Reviewed By: javache

Differential Revision: D3392223

fbshipit-source-id: 67c36fbe16fe493e2841d5d9deb78e3be2209ebd
2016-06-06 10:13:28 -07:00
Siqi Liu 61046c3195 Fix the bug where key shortcuts are invoked in TextInputs in iOS
Summary:
This is a followup for "Add Shortcut "Double R" to Reload JS in iOS".
Please see the previous two revisions:[[ D3371536 | D3371536 ]], [[ D3343907 | D3343907 ]]

In previous revisions, we only tested with the iOS UIExplorer app, without testing in the iOS Catalyst app, where the key shortcuts we added are always invoked in TextInput components. It's due to a bug with the `UIApplicationDelegate`. Just fix this bug in this revision and successfully tested in the Catalyst app.

Reviewed By: mkonicek

Differential Revision: D3391045

fbshipit-source-id: 8b76fbfe7592218b02dd22502d25eebbc59f3cbc
2016-06-06 09:43:17 -07:00
Joshua Pinter 5b4b027477 Add get scheduled local notifications
Summary:
_(This is a remake of #6907, which I botched pretty good with a rebase.)_

This returns an `Array` of Local Notifications that have been scheduled to be delivered.

Available attributes on return Notification object (if set in the local notification itself):

`alertAction`
`alertBody`
`applicationIconBadgeNumber`
`category`
`fireDate`
`soundName`
`userInfo`

More could be added to this but I just matched what was available in the `Object` passed to `presentLocalNotification` and `scheduleLocalNotification`.

**Motivation**

I needed to determine the number and other details about local notifications that were already scheduled. There is an API for this in iOS but one hadn't been built yet for React Native.

I created the Obj-C method and updated the documentation in `PushNotificationIOS.js` as well.

**Usage:**

```js
PushNotificationIOS.getScheduledLocalNotifications( (notifications) => {
  console.log(notifications);
});
```

**Sample Output:**

```js
[
  Object {
    aler
Closes https://github.com/facebook/react-native/pull/7937

Differential Revision: D3392476

Pulled By: javache

fbshipit-source-id: d83f419bfcfbdaf9b955724dcf5cfe26834895fb
2016-06-06 09:28:24 -07:00
Pieter De Baets 4de616b4c1 Remove deprecated calls from StatusBarIOS
Reviewed By: nicklockwood

Differential Revision: D3346701

fbshipit-source-id: 17809a4cd686f3b431257e85d85770aee640bbc9
2016-06-06 09:13:24 -07:00
Nick Lockwood 72b363d7fc Replaced isMainThread checks with a proper test for main queue
Summary:
As per https://twitter.com/olebegemann/status/738656134731599872, our use of "main thread" to mean "main queue" seems to be unsafe.

This diff replaces the `NSThread.isMainQueue` checks with dispatch_get_specific(), which is the recommended approach.

I've also replaced all use of "MainThread" terminology with "MainQueue", and taken the opportunity to deprecate the "sync" param of `RCTExecuteOnMainThread()`, which, while we do still use it in a few places, is incredibly unsafe and shouldn't be encouraged.

Reviewed By: javache

Differential Revision: D3384910

fbshipit-source-id: ea7c216013372267b82eb25a38db5eb4cd46a089
2016-06-06 07:58:36 -07:00
Nick Lockwood 1048e5d344 Fixed removeClippedSubviews
Summary:
The `removeClippedSubviews` feature works by umounting views from the hierarchy if they move outside the bounds of their parent.

This was previously restricted to clipping views which had `overflow: hidden`, since we cannot efficiently check whether the subviews of a view go outside its bounds, and so clipping a view that has potentially overflowing children becomes an expensive recursive operation.

The problem with this is that `overflow: visible` is the default, and it's not well documented nor easy to tell that `removeClippedSubviews` has been set up correctly (i.e. with all children having `overflow: hidden`).

When I checked, I found that `removeClippedSubviews` was not working on any of the examples in UIExplorer, nor in several of our internal apps, because the views inside the ListView has `overflow: visible`. This was probably caused by an infra change at some point, but I'm not sure how long it's been broken.

It's vanishingly unlikely that anyone would ever deliberately want subviews to overflow their bounds in this scenario, so I've updated the logic to simply ignore the `overflow` property and assume that views should be clipped if you are using the `removeClippedSubviews` property on the parent.

Cons / Breaking changes: in some rare circumstances, a view might get clipped prematurely if its parent is outside the scrollview bounds, but it itself is inside. This doesn't occur in practice in any of our products, and could be worked around with additional wrapper views if it did.

Pros: removeClippedSubviews is now much easier to use, and much more likely to work as intended, so most list-based apps should see a performance improvement.

Reviewed By: javache

Differential Revision: D3385316

fbshipit-source-id: 1c0064a4c21340a971ba80d794062a356ae6cfb3
2016-06-06 07:58:35 -07:00
dragonwong 8731494990 change leftButton init position
Summary:
In navigationBar, when back to the previous view, the left button of the previous view should fade in like iOS native navBar, instead of move in. It's interesting that the right button acts correct.

React Native:

![clear](https://cloud.githubusercontent.com/assets/2622602/15535443/fa5e77bc-229f-11e6-8632-0dd9f5f2fb26.gif)

iOS Native:

![clear2](https://cloud.githubusercontent.com/assets/2622602/15535452/05999918-22a0-11e6-877c-63590b7bb9ef.gif)
Closes https://github.com/facebook/react-native/pull/7745

Differential Revision: D3392307

Pulled By: nicklockwood

fbshipit-source-id: e5384140049bf7b6f78fc093209ee48814a2ffdc
2016-06-06 07:28:24 -07:00
Nick Lockwood 329c716897 Fixed bug where layoutSubviews was called continuously for scrollview
Summary:
RCTScrollView was calling `dockClosestSectionHeader` in `reactBridgeDidFinishTransaction`, which triggers a layout update. The reason for this was in case the `stickyHeaderIndexes` property was updated, which would require the headers to be adjusted.

However, doing this in `reactBridgeDidFinishTransaction` had the affect of causing `layoutSubviews` to be called repeatedly every frame even if nothing had changed and the scrollview wasn't moving, which was especially expensive when combined with the `removeClippedSubviews` logic, that loops through every view to calculate if it needs to be clipped.

This fix moves the `dockClosestSectionHeader` call into `didUpdateProps`, and checks that the stickyHeaderIndexes have actually changed before calling it.

Reviewed By: javache

Differential Revision: D3387607

fbshipit-source-id: c71e00c6fac48337a63d7fee7c7c23e016acf24e
2016-06-06 05:28:31 -07:00
Mike Grabowski a8d4fbb5b2 Add upcoming releases to the schedule
Summary: Closes https://github.com/facebook/react-native/pull/7947

Differential Revision: D3392139

fbshipit-source-id: aa7c0dd760d4922e44eb1b36e8d4f599d81ba680
2016-06-06 04:43:29 -07:00
Konstantin Raev 2aad61650e Open sourced more instrumentation tests #1
Reviewed By: avaly

Differential Revision: D3366104

fbshipit-source-id: 1c77b29e28726a6a105317d9f6944bbf78b707d7
2016-06-06 04:28:44 -07:00
Andrei Coman 4acf009284 Pass resource drawable id to constructor directly
Summary:
Instead of passing the helper to each method that uses it, just pass it
to the image constructor.

Reviewed By: dmmiller

Differential Revision: D3364532

fbshipit-source-id: 949bdbf951875c9b8cd05d028a2c329e12d72042
2016-06-06 04:28:43 -07:00
Ricky Reusser c36430a0d6 Hook up Android intent to Linking.js #7079
Summary:
Fixed #7118 by rreusser
Closes https://github.com/facebook/react-native/pull/7940

Differential Revision: D3391586

fbshipit-source-id: f7e572a91347fb0629602374cb6944eabf5b0e8f
2016-06-05 18:58:24 -07:00