Summary: This prevents the 'distanceFromEnd' from being negative when 'offset' is zero, for example.
Closes https://github.com/facebook/react-native/pull/3074
Reviewed By: svcscm
Differential Revision: D2610771
Pulled By: sahrens
fb-gh-sync-id: f878f1c1b865063294013c3bb96b90831877d372
Summary: public
The Dev Menu is for some reason eventually calling twice the callbacks, guard
against it while we don't fix it.
Reviewed By: nicklockwood
Differential Revision: D2600470
fb-gh-sync-id: 50c622d2ab64ce50d51572dbfcc076c2765ce582
Summary: A lot of people try to use a device as the very first thing when trying
out React Native. I've observed this at the developer workshop in Prague
and on Twitter.
However, developing on pre-API 21 devices is quite involved:
https://facebook.github.io/react-native/docs/running-on-device-android.html
I'm thinking we could recommend installing Android together with Android
studio. Android studio installs HAXM for you (hardware acceleration, without
this Google emulators are useless) and also creates and starts emulators.
So it would be quite a smooth experience similar to pressing 'Run' in Xcode.
We'd just need to integrate with Gradle so that installing the app also starts
the packager. I think that's something we should do in any case.
Probably an even better option is to build a React Native-specific tool that
lets you do everything you need: opens the Android SDK Manager, creates and
starts emulators, detects whether you have Genymotion and opens it, upgrades
node and npm etc.
public
Reviewed By: vjeux
Differential Revision: D2604774
fb-gh-sync-id: c7ffb701b4e5209815faf652926937c22943be95
Summary: public
The UIManager had a lock around the enqueued ui blocks, but now all the operations
should happen on the shadow thread, so I added assertions to it and removed the
locks.
Reviewed By: nicklockwood
Differential Revision: D2605760
fb-gh-sync-id: e1bc649f759502e7e9fd059932e0cba38dba05bf
Summary: public
At some point the profile call was changed to only pass `@"invoke callback"`
rather than the module name, which makes most entries pretty much useless.
Change it back to be the module name.
Reviewed By: javache
Differential Revision: D2602222
fb-gh-sync-id: c4e8e3f559f66725620293cc575baf5ede48df31
Summary: Inspired by: https://twitter.com/geirmanc/status/660275638637477889
There are many reasons why the Gradle build could fail and the best
thing to do is to read the error message.
We can provide some hints in the most common cases though.
public
Reviewed By: vjeux
Differential Revision: D2604747
fb-gh-sync-id: 1aa83abb9ec823c03814dcc31d630a8f1914cf5c
Summary: public
Add explicitly cast to the trampoline prototype to silence warnings.
Reviewed By: javache
Differential Revision: D2605779
fb-gh-sync-id: e208b69236c1b87bb1374ee493840ea5f47b371c
Summary: public
Native iOS has a good error message, but it's in native which makes
things a little harder to track down (can't use Chrome debugger as easily).
Android has no special handling, so a cryptic "Trying to add unknown view tag..."
redbox would come up.
This puts the error handling in JS so it's shared on all platforms and can be
debugged more easily in Chrome.
Reviewed By: vjeux
Differential Revision: D2606064
fb-gh-sync-id: 5295a44a028c7be79d60dbaf0b5d59fd0a56fdde
Summary: releasing the viewControllers referred by _navigationController.viewControllers, which is also releasing the related views
Closes https://github.com/facebook/react-native/pull/3808
Reviewed By: svcscm
Differential Revision: D2604735
Pulled By: javache
fb-gh-sync-id: f202d155f04169f3f0f0ef26365b37b8525b6687
Summary: public
White space between the end of the first part of the method selector and the first colon was being included in the JS method name.
(See: https://github.com/facebook/react-native/issues/3804)
Reviewed By: javache
Differential Revision: D2605713
fb-gh-sync-id: b4402c9ede5eb31dd38021c902f046a4e0557814
Summary: public
Expose a more precise timer, millisecond precision is enough to measure small operations.
Reviewed By: javache
Differential Revision: D2604218
fb-gh-sync-id: ba50c891b5690575548fe04ba1ae7d015bc31d90
Summary: public
We moved to using `new` instead of `alloc] init` but there was still some calls
left.
Reviewed By: javache
Differential Revision: D2604679
fb-gh-sync-id: ff7300ecbedb55dd5e93873592598810c9b87808
Summary: public
After reloading the JS side of the profiler wasn't being reenabled.
Reviewed By: javache
Differential Revision: D2602258
fb-gh-sync-id: 5de8afb829e9fa8225600e2b0ff9e00313ac1d4c
Summary: public
Call the native bindings explicitly from BridgeProfiling instead of polyfill'ing `console.profile` with
a function that has a different signature.
Reviewed By: vjeux
Differential Revision: D2602313
fb-gh-sync-id: 9295eff9458f2caa35b7e982c0f7c06dbe65fd09