Commit Graph

4478 Commits

Author SHA1 Message Date
Nick Lockwood 9901bf20e1 Fixed image source for MapView annotations
Summary:
public
resolveAssetSource was not being called on MapView image any more, resulting in an error when using `require(./imagename.png)` syntax.

Reviewed By: fredliu

Differential Revision: D2772560

fb-gh-sync-id: 0a50a9c3ba727406343a0f47c84941e95df9cadd
2015-12-18 00:50:30 -08:00
Denis Koroskin 56fd138fd3 Dispatch OnLayoutEvent when node gets re-laid out
Reviewed By: ahmedre

Differential Revision: D2768625

fb-gh-sync-id: 4a9862e4c7ada218565fcd87cae25414a0bd5181
2015-12-17 18:46:27 -08:00
Pieter De Baets 5b4e873c68 Guard against invalid JS bundle
Reviewed By: tadeuzagallo

Differential Revision: D2767961

fb-gh-sync-id: 4e9162ddbb2986a56dd129743e316d6e83bb8cb3
2015-12-17 17:26:33 -08:00
Nick Lockwood ba3a5f0eec Removed overly-strict typing in MapViewExample
Summary:
public

While it's nice to see such a masterclass in strict typing with Flow, having it an example serves no useful purpose, and makes the example unnecessarily fragile with respect to API changes.

Reviewed By: gabelevi

Differential Revision: D2769981

fb-gh-sync-id: db5550d5674bf32ef8d331861751a4e6aa1f6536
2015-12-17 16:34:09 -08:00
Denis Koroskin 18d2177989 Implement @ReactProp nativeBackgroundAndroid in RCTView
Reviewed By: ahmedre

Differential Revision: D2768671

fb-gh-sync-id: cb3ae29f1cecfaec103708cbc82cf4b57dc80d1a
2015-12-17 15:05:45 -08:00
Louis Pilfold c9410d0673 Add support for nodenv with xcode
Summary:
Hello!

I'm a fan of the *env family of version managers over the *vm family as I find them simpler and less obtrusive, but it seems that they don't currently work so well with react-native on OSX. See #4645

I've made a small addition to the xcode script that resolves the issue for me. Hopefully others will find this useful too :)

If I've not made the right move here, what is the correct way to get react-native projects building in xcode when the binary is not in the $PATH used by the script?

Cheers,
Louis
Closes https://github.com/facebook/react-native/pull/4801

Reviewed By: svcscm

Differential Revision: D2770726

Pulled By: androidtrunkagent

fb-gh-sync-id: 3b0f9e466549b3012a68c94738d2556173f4c21e
2015-12-17 14:10:36 -08:00
Denis Koroskin ad74dabb68 Turn FlatViewManager into ViewGroupManager
Reviewed By: ahmedre

Differential Revision: D2768667

fb-gh-sync-id: 39298e4033aab5ca8230516f98da252790811f14
2015-12-17 13:31:31 -08:00
Jing Chen 022eac9bd8 Revert D2739392 to fix events dash loading on android
Reviewed By: andreicoman11

Differential Revision: D2770201

fb-gh-sync-id: 6391936f41ba18606637c801645c3177ed1da9ea
2015-12-17 12:54:37 -08:00
Martin Konicek 8cd7730080 Open source Android WebView
Summary:
Keep `WebView.android.js` and `WebView.ios.js`, there are
some small differences. Use the same example on both platforms.

public

Reviewed By: bestander

Differential Revision: D2769446

fb-gh-sync-id: be3d0afcbfd6ddcbaa49f70555063b3081ba03cb
2015-12-17 12:47:39 -08:00
Adam Miskiewicz 8b03b9654d Merge pull request #4846 from qbig/minor-doc-animation
[Doc][Minor] updated deprecated sample code in animation doc
2015-12-17 15:07:10 -05:00
Martin Konicek 3a3af8a385 Open souce the Android Dialog module
Summary:
public

The `DialogModule` requires `android.support.v4.app.FragmentManager` which means
every app that wants to use Dialogs would need to have its Activity extend the legacy
`android.support.v4.app.FragmentActivity`.

This diff makes the `DialogModule` work with both the Support `FragmentManager`
(for AdsManager & potentially other fb apps) and the `android.app.FragmentManager`
(for new apps with no legacy dependencies).

Also wrap the native module in the same `Alert` API that we have on iOS and provide
a cross-platform example. In my opinion the iOS Alert API is quite nice and easy to use.

We still keep `AlertIOS` around because of its `prompt` function which is iOS-specific
and also for backwards compatibility.

Reviewed By: foghina

Differential Revision: D2647000

fb-gh-sync-id: e2280451890bff58bd9c933ab53cd99055403858
2015-12-17 11:11:13 -08:00
Andrew Crowell fe86771a22 Maintain cursor position when TextInput value is changed programmatically
Summary:
This is useful for applying input masks in the onChange handler that you then need to propagate down to the native component. In our case, we add commas as the user enters a price. Without this change, the cursor will end up in the wrong place when the text is transformed in our onChange handler.
Closes https://github.com/facebook/react-native/pull/4716

Reviewed By: svcscm

Differential Revision: D2766236

Pulled By: nicklockwood

fb-gh-sync-id: c4057d77d62507ec9e09eb0242888bf2858d822f
2015-12-17 10:23:26 -08:00
Christopher Chedeau 7f2940e160 Merge pull request #4847 from dabit3/showcase-work-well-on-mobile
fixed showcase to display well on mobile
2015-12-17 09:14:41 -08:00
Nader Dabit 606b914209 fixed showcase to display well on mobile 2015-12-17 10:35:16 -06:00
Qiao Liang 521983480a updated deprecated sample code in animation doc 2015-12-18 00:11:00 +08:00
Nick Lockwood f9dfb90a35 Added ability to use a custom view for MapView annotations
Summary:
public
This diff adds the ability to specify a custom React component (aka view) to be displayed as a MapView pin.

This makes it possible to use remote images (using an <Image/> component), or text (using a <Text/> component), or anything else.

One consequence of this is that MapView can no longer support arbitrary subviews. To place views in front the map, add them to a separate container view.

Reviewed By: tadeuzagallo

Differential Revision: D2764790

fb-gh-sync-id: e16b44e866c2d76c76b0cb35ef9eefbfc68d6719
2015-12-17 06:46:33 -08:00
Satyajit Sahoo 97c75cf5a4 Merge pull request #4839 from LukeAvery92/master
added WEARVR app to showcase
2015-12-17 18:40:06 +05:30
luke.avery f58f3913c0 added WEARVR app to showcase 2015-12-17 11:30:17 +00:00
Pasindu Perera 5da0e135b6 npm progress shown on react init
fixes #3771 for npm 5 and upwards
2015-12-17 14:04:18 +05:30
Pieter De Baets b40631b3cc Remove unused RKAnalyticsCPULogger
Reviewed By: bryceredd

Differential Revision: D2766801

fb-gh-sync-id: c5088c01bbae6a10b17317cc5ec2adcf157f415e
2015-12-16 16:16:28 -08:00
Jorge Maroto 2a241a242b Move Image.resizeMode to component
Summary:
Using resizeMode on Image component returns a warning, it needs to be passed by param
Closes https://github.com/facebook/react-native/pull/4791

Reviewed By: svcscm

Differential Revision: D2767093

Pulled By: spicyj

fb-gh-sync-id: 5ab6a2e949d4c68244b5e890a429aaf1f15118a9
2015-12-16 16:00:36 -08:00
Sameer Rahmani f48961388e FloatFromLeft scene configuration fixed. HorizontalSwipeJumpFromRight…
Summary:
`FloatFromLeft` configuration was wrong. its animation was ok but the swipe back was wrong. for example you had to swipe from left to right for a `back` action which should be swipe from right to left.

`HorizontalSwipeJumpFromRight` is the same as `HorizontalSwipeJump` but for RTL layouts.
Closes https://github.com/facebook/react-native/pull/4815

Reviewed By: svcscm

Differential Revision: D2766720

Pulled By: androidtrunkagent

fb-gh-sync-id: 2b60f2d238a8f8e5b27dbfb307887934be477c81
2015-12-16 15:08:44 -08:00
James Ide d52723efec [README] Add Circle CI status to the README 2015-12-16 14:24:22 -08:00
David Aurelio 12778f3bc6 fork unbundle output format per platform
Summary:
We decided to use different storage formats for android and ios. This diff changes the output format to asset files if the platform is `'android'`.

public

Reviewed By: martinbigio

Differential Revision: D2764739

fb-gh-sync-id: 4a5ac13ba7978112e9424573643e90cef2a1b75f
2015-12-16 12:01:17 -08:00
Mike Armstrong 1be5777265 define out the memory heap jsc functions
Reviewed By: mkonicek

Differential Revision: D2764964

fb-gh-sync-id: 26eff3e29762287f3527de84b146cee90eccd580
2015-12-16 10:45:52 -08:00
Denis Koroskin 42a1620b1e Remove referenced to dropped views
Reviewed By: ahmedre

Differential Revision: D2757310

fb-gh-sync-id: 2ac97476823879d60dac63920f5e7f086872888a
2015-12-16 10:06:31 -08:00
Adam Miskiewicz e5e846ab0a Merge pull request #4826 from Intellicode/master
Add 'Pimmr' to Showcase page
2015-12-16 11:47:36 -05:00
Marc Shilling f48dbbecd6 Fix getCurrentPosition
Summary:
Instantiates the _pendingRequests array before trying to add to it. As it currently stands, we try to add the pending request before the array is created. getCurrentPosition always fails on the first try.
Closes https://github.com/facebook/react-native/pull/4764

Reviewed By: svcscm

Differential Revision: D2764751

Pulled By: androidtrunkagent

fb-gh-sync-id: 411a03ff16d40725d8cc0909607632045eb5a27b
2015-12-16 08:37:33 -08:00
Tom Hastjarjanto a38cd48737 Remove part of query string 2015-12-16 17:32:27 +01:00
Tom Hastjarjanto d131fa0962 Add Pimmr to showcase 2015-12-16 17:30:43 +01:00
Christopher Chedeau 92fb0c44d0 Merge pull request #4825 from qbig/add-more-videos-to-doc
[Doc][Minor] embed more videos
2015-12-16 08:21:38 -08:00
Qiao Liang 0c09f38aa1 embed more videos 2015-12-17 00:09:49 +08:00
Martin Konicek 7e146fac37 Merge pull request #4809 from isair/patch-2
[packager][README] "find can more" -> "can find more"
2015-12-16 14:06:50 +00:00
Martin Konicek f6e6cae2ed Merge pull request #4806 from morenoh149/wrapJS
[docs] Wrap javascript at 80 columns
2015-12-16 14:06:13 +00:00
Elliot Hesp 6ddcef8a23 Update to PullToRefreshViewAndroid docs
Summary:
As mentioned in https://github.com/facebook/react-native/issues/4793 it is not initially clear that the PullToRefreshViewAndroid component needs the `{flex: 1}` style in order for it's child component to function correctly (without examining the example). This will hopefully clear that up.
Closes https://github.com/facebook/react-native/pull/4814

Reviewed By: svcscm

Differential Revision: D2764534

Pulled By: androidtrunkagent

fb-gh-sync-id: ae1c529342e85f8348b4f683e42bf25df5dbea09
2015-12-16 05:17:30 -08:00
Milen Dzhumerov 1304e78136 Inline require ExceptionsManager dependencies
Summary:
Inline require `ExceptionsManager` dependencies which are eagerly loaded on app startup (via `setUpConsole()` which is called from `InitializeJavaScriptAppEngine.js`) even though it's necessary until an exception needs to be reported.

This can save about 30-40ms on an iOS device.

public

Reviewed By: nicklockwood, tadeuzagallo, jspahrsummers

Differential Revision: D2755161

fb-gh-sync-id: d4cbfebf04d861b3a70558346a395d3d3ee87cc6
2015-12-16 04:02:30 -08:00
Tadeu Zagallo 809627379b Rename RCTContextExecutor to RCTJSCExecutor
Summary:
public

Rename the executor to so it actually says something about the implementation.

Reviewed By: jspahrsummers, nicklockwood

Differential Revision: D2759688

fb-gh-sync-id: 5b1ac447e75109fbbc2ee71c804710d9926785aa
2015-12-16 02:51:28 -08:00
Tadeu Zagallo f8c125c64b Remove redundant profile events
Summary:
public

Remove some of the manual markers from the bridge since they will already be added dinamically.

Reviewed By: jspahrsummers

Differential Revision: D2761748

fb-gh-sync-id: 0c726373f9105258feb8230d30453559ed1e6a65
2015-12-16 02:31:29 -08:00
Tadeu Zagallo f5673026f4 Remove expensive args from profile markers
Summary:
public

We were adding all the arguments passed to all the JS functions and callbacks
called over the bridge to marker names, and this args can be huge, meaning a lot
of time spent stringifying arguments and therefore less accurate profile results

Reviewed By: nicklockwood

Differential Revision: D2761809

fb-gh-sync-id: 2d0b5b90cc9e59fe491c108b0360b84ab5fee5b7
2015-12-16 02:13:28 -08:00
Tim Yung 8457a46e43 RN: Install Updated `fbjs` Downstream
Reviewed By: cpojer

Differential Revision: D2754195

fb-gh-sync-id: 67b628fdfa34da379ab5fdad03b1baaf767c7f21
2015-12-16 01:49:15 -08:00
Dave Miller fcf0431d25 Add support for more Scroll Events to Android
Summary:
public
This adds support for
onScrollBeginDrag/End
onMomentumScrolBegin/End

Reviewed By: astreet

Differential Revision: D2739035

fb-gh-sync-id: 2a49d1df54e5f5cd82008bdb0ffde0881ba39aff
2015-12-16 00:48:28 -08:00
Denis Koroskin 1fabd86048 Add support for custom AndroidViews
Reviewed By: ahmedre

Differential Revision: D2751716

fb-gh-sync-id: 3007cc1eb0303bb2e9eab84836b486e1c2e21021
2015-12-15 20:08:34 -08:00
Baris Sencan 75d81cfb10 [README] "find can more" -> "can find more" 2015-12-15 18:34:19 -08:00
Qiao Liang edc318fcb9 added doc for image resizeMode
Summary:
based on 62e8ddc205/ReactAndroid/src/main/java/com/facebook/react/views/image/ImageResizeMode.java  and http://developer.android.com/reference/android/widget/ImageView.ScaleType.html
Closes https://github.com/facebook/react-native/pull/4799

Reviewed By: svcscm

Differential Revision: D2762795

Pulled By: androidtrunkagent

fb-gh-sync-id: 2906c9f334f0afd4d58d4864a2b8472a5a871fc0
2015-12-15 17:34:29 -08:00
Hedger Wang 53d18c83c8 Fix app crash caused by TextInput.
Reviewed By: zjj010104

Differential Revision: D2761644

fb-gh-sync-id: 89241de2f8c84d569ec452871f740a0d655cc95e
2015-12-15 17:32:27 -08:00
Harry Moreno ca263ac8a1 wrap javascript at 80 columns 2015-12-15 19:33:18 -05:00
James Ide 4e2a31685c Merge pull request #4800 from pedro/lugg
showcase Lugg's android app
2015-12-15 16:27:06 -08:00
James Ide 558b00653c Merge pull request #4804 from morenoh149/noteReadableMap
Add link to more info for ReadableMap and ReadableArray
2015-12-15 16:25:37 -08:00
Hedger Wang 67c6afd14b immediatelyResetRouteStack does not update Navigator's title
Summary:
re-render the whole navigation bar while calling immediatelyResetRouteStack
from navigator.

Reviewed By: zjj010104

Differential Revision: D2751922

fb-gh-sync-id: 79bcd1457a96eaf3ca94b81da9bfecbec7f8af46
2015-12-15 15:40:27 -08:00
Tadeu Zagallo e39657aaae RCTPerformanceNow -> nativePerformanceNow
Summary:
public

Rename `RCTPerformanceNow` to `nativePerformanceNow` to be consistent with Android
and the pattern we've been following where the native functions exposed to JSC
are prefixed with `native`.

Also change it to return fractional milliseconds, as the web (`performance.now`)
does: https://developer.mozilla.org/en-US/docs/Web/API/Performance/now

Reviewed By: mikearmstrong001

Differential Revision: D2755287

fb-gh-sync-id: 2acada5673633858ae0bbcdcfae554183e36cb24
2015-12-15 14:52:30 -08:00