408 Commits

Author SHA1 Message Date
Ben Alpert
63ab6e8281 [react-native] Remove iOS-specific attributes from ART text 2015-04-30 13:23:16 -08:00
Ben Alpert
4f70e58b37 [react-native] Only intercept console.error on iOS 2015-04-30 12:06:47 -08:00
Andrei Coman
8fe6626d5f [react_native] JS files from D2028144: [react_native] Expose android version to JS 2015-04-30 11:42:14 -08:00
Nick Lockwood
eb0476074f Improved debug and fixed macros 2015-04-30 09:59:16 -08:00
Ben Alpert
261a0af9bb [react-native] Fix Chrome debugging
Summary:
Requiring ExceptionsManager in renderApplication (added in D2023119) led to a transitive require of ExecutionEnvironment, which has to run after InitializeJavaScriptAppEngine.

InitializeJavaScriptAppEngine is the right place for this sort of logic because we control the order that things are loaded, so move the console.error hook initialization there.

@public

Test Plan: Loaded shell app in simulator with Chrome debugging with no errors.
2015-04-30 02:16:40 -08:00
Eric Vicenti
08ec846176 [ReactNative] Fix logic in popToRoute 2015-04-29 20:52:32 -08:00
Ben Alpert
d8ab648fce Updates from Wed 29 Apr 2015-04-29 18:55:07 -07:00
Hedger Wang
4ac2fcc4a6 [madman][android]: unbreak android app. 2015-04-29 15:38:10 -08:00
Nick Lockwood
81e82d10ab Added missing features from Multiline Text commit 2015-04-29 15:27:15 -08:00
Ben Alpert
c6af33e796 [react-native] Open-source ReactART for native 2015-04-29 15:21:48 -08:00
Andy Street
96850b7429 [react_native] JS files from D2027955: [react_native] Add bridge 'spy mode' to watch bridge traffic 2015-04-29 11:49:05 -08:00
Clay Allsopp
11f204748d Add SegmentedControlIOS
Summary:
Fixes #534:

![screen shot 2015-03-31 at 7 52 10 pm](https://cloud.githubusercontent.com/assets/153704/6934038/742ddd34-d7e3-11e4-8f55-3eb7d9d3f1cd.png)

```jsx
<SegmentedControlIOS
  tintColor="#ff0000"
  values={['One', 'Two', 'Three', 'Four']}
  selectedtIndex={0}
  momentary={false}
  enabled={true}
  onValueChange={ (value) => console.log(value) } />
```

This only supports string-based segments, not images. Also doesn't support full customization (no separator images etc); I figure this is a good MVP to lock-down a basic API

I also included a snapshot test case, but the images keep coming out funky. When I look at the sim, I see that the text labels show up for the selected segment, but the snapshot keeps coming out with no text on those segments. I tried forcing a delay, but same result. Is that explainable?

Obviously happy to change anything about the API, code-style nitpicks, etc
Closes https://github.com/facebook/react-native/pull/564
Github Author: Clay Allsopp <clay.allsopp@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-29 08:08:45 -08:00
Andy Street
c82c6a07ae [react_native] JS files from D2027859: [react_native] Fix ToTheLeft wizard transitions 2015-04-29 04:49:43 -08:00
Brent Vatne
c09bdebcd5 Add support for multiline TextInput via UITextView
Summary:
@nicklockwood - Could I get a review of this?

Just took `RCTTextField` and ported it from `UITextField` to `UITextView` as you mentioned in another discussion, and removed any `UITextField` specific attributes.

- How do you think this should behave when there are subviews?
- Do you know how we can respond to the `UIControlEventEditingDidEndOnExit` event to respond to submit? Because `UITextView` isn't a `UIControl` we can't just use `addTarget` with `UIControlEventEditingDidEndOnExit`.
- Any other feedback?

Still going to look over the `UITextView` docs in more detail and make sure we expose all important options, and add it to the UIExplorer example, just putting this out here for feedback.

![multiline](https://cloud.githubusercontent.com/assets/90494/7310854/32174d6a-e9e8-11e4-919e-71e54cf3c739.gif)

Closes https://github.com/facebook/react-native/pull/991
Github Author: Brent Vatne <brent.vatne@madriska.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-29 01:33:58 -08:00
Eric Vicenti
349f8b942a [ReactNative] Avoid Navigator invariant in edge case
Summary:
It is very rare, but sometimes there is no active gesture when the responder gets released. This will avoid a redbox in that case

@public

Test Plan: Saw the redbox. No longer see the redbox. Hardcoded missing activeGesture while responder and verified no redbox
2015-04-28 23:53:39 -08:00
Spencer Ahrens
ecf7baebea [React Native] Actually bring back console.error redboxes with disable flag 2015-04-28 14:53:36 -08:00
Eric Vicenti
9209c444c7 [ReactNative] Androidized Navigator animations
Summary:
Added configurations for android-like animations, with gestures disabled.

@public

Test Plan: Tested on AdsManager Android
2015-04-28 13:10:49 -08:00
Nick Lockwood
48297753cf Refactored RKSounds, moved it into it's own library, and fixed tests 2015-04-28 10:53:53 -08:00
Philipp von Weitershausen
f2b38bacbf [ReactNative] parse localized JSON files in JS, not in ObjC 2015-04-28 09:52:35 -08:00
Nick Lockwood
bc24be8584 Fixed nil object insertion crash due to incorrectly encoded HTTP response body data 2015-04-28 04:48:32 -08:00
Eric Vicenti
8afdf30363 [ReactNative] Navigator refactor and improvements 2015-04-27 21:37:33 -08:00
Spencer Ahrens
473acdbc74 [ReactNative] Fix fatal from long press 2015-04-27 20:46:23 -08:00
Eric Vicenti
ec3d70e738 [ReactNative] Quiet Navigator context warning 2015-04-27 17:31:12 -08:00
Eric Vicenti
6749f88650 [ReactNative] Fix Navigator resetTo 2015-04-27 17:18:52 -08:00
Gabe Levi
b6e6dae6ba [Flow] Properly fix new errors as of Flow v0.10. 2015-04-27 14:56:21 -08:00
Ben Alpert
dd56ccb9c7 [react-native] Fix capitalization of "REact" 2015-04-27 13:52:57 -08:00
Eric Vicenti
3f723f451d [ReactNative][RFC] Yellow Box for warnings 2015-04-27 13:32:22 -08:00
Maksim Bunkow
bae4e44c60 Added placeholderTextColor property for TextInput class
Summary:
Closes https://github.com/facebook/react-native/pull/997
Github Author: Maksim Bunkow <bimawa@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-27 10:43:10 -08:00
Tadeu Zagallo
136431cc2f [ReactNative] Fix struct args on exported methods 2015-04-27 04:01:37 -08:00
Gabe Levi
70c9f5140d Clean the errors that Flow v0.10.0 finds 2015-04-26 18:31:53 -04:00
Nick Lockwood
77e38b26c5 Improved RCTActivityIndicatorView and fixed some flow errors 2015-04-26 02:17:13 -08:00
Spencer Ahrens
1cc0c96508 [React Native] Bring back console.error redboxes with disable flag 2015-04-24 17:54:16 -08:00
Spencer Ahrens
68eb3e4906 [ReactNative] geolocation method docs 2015-04-24 16:26:28 -08:00
Spencer Ahrens
a2dd7fc69f [ReactNative] Fix dimensions in jest tests 2015-04-24 14:00:35 -08:00
Spencer Ahrens
8465859411 Fix doc generation for Geolocation 2015-04-24 13:14:24 -07:00
Krzysztof Magiera
46db1826c5 [react_native] JS files from D2017699: Expose JavaScriptEnabled property for WebView component on android. 2015-04-24 11:53:35 -08:00
Spencer Ahrens
5225acea01 Fix tests 2015-04-24 12:15:11 -07:00
Alex Kotliarskyi
970bff6132 [ReactNative] Enable resolveAssetSource for Image.android 2015-04-24 10:56:04 -08:00
Spencer Ahrens
21b4b5b352 Updates from Fri 24 Apr 2015-04-24 11:46:18 -07:00
Kevin Gozali
d094952725 [ReactNative] Re-applied D2011598 2015-04-24 10:33:41 -08:00
Andrei Coman
a635a73abc [react_native] JS files from D2020585: [react_native] Remove focus for TextInputs when they unmount 2015-04-24 09:49:39 -08:00
Tadeu Zagallo
d293bed5ab [ReactNative] Fix analyze errors on oss 2015-04-24 08:28:35 -08:00
Felix Oghina
d354c7dd91 [react_native] JS files from D2009062: add geolocation support 2015-04-24 02:24:18 -08:00
Ben Alpert
dd6f7743eb Fix updating RCTText with new text of the same size
Summary:
Fixes #979.

Previously, a Text whose width is determined automatically (as opposed to set by a container) would position the text incorrectly after an update to the text *if* the text's width did not change (i.e., when changing only digits in a font with tabular numbers).

Every time RCTShadowText's RCTMeasure runs, it sets the text container's size to be the maximum allowed size for the text. When RCTText's drawRect is called later, it relied on layoutSubviews having been called to set the text container's size back to the proper width. But if RCTMeasure returned the same dimensions as last time, then RCTText's frame wasn't reset and so layoutSubviews was never re-called. With this change, we set the textContainer's size each time we draw the text.

We could also fix this by using a different NSTextContainer instance in RCTMeasure. Not sure what the pros and cons of that are.
Closes https://github.com/facebook/react-native/pull/989
Github Author: Ben Alpert <balpert@fb.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-23 16:12:35 -08:00
Kevin Gozali
ee3986342a [ReactNative][madman] Revert D2011598 temporarily 2015-04-23 15:12:01 -08:00
Eric Vicenti
36afc46274 [ReactNative] Fix for Navigator.replacePreviousAndPop 2015-04-23 14:19:44 -08:00
Philipp von Weitershausen
e88ba1a6a3 [ReactNative] Back out D2014163 entirely 2015-04-23 12:02:47 -08:00
Bill Fisher
357a54500e Implement transform styles, redux 2015-04-23 10:17:39 -08:00
Alex Kotliarskyi
7de74b129d [ReactNative] Move NativeModules mock to OSS 2015-04-23 09:35:55 -08:00
Jakub Zika
e293efbfb1 Bump .buckversion to 6cdb82cb7493a86c39d0f0dc3c102d0f470f55de. 2015-04-23 08:24:08 -08:00