├── .gitignore
├── .npmignore
├── LICENSE
├── README.md
├── android
├── build.gradle
└── src
│ └── main
│ ├── AndroidManifest.xml
│ └── java
│ └── com
│ └── rnds
│ ├── DirectedScrollView.java
│ ├── DirectedScrollViewChild.java
│ ├── DirectedScrollViewChildManager.java
│ ├── DirectedScrollViewManager.java
│ └── DirectedScrollViewPackage.java
├── example
├── .babelrc
├── .buckconfig
├── .flowconfig
├── .gitattributes
├── .gitignore
├── .watchmanconfig
├── android
│ ├── app
│ │ ├── BUCK
│ │ ├── build.gradle
│ │ ├── proguard-rules.pro
│ │ └── src
│ │ │ └── main
│ │ │ ├── AndroidManifest.xml
│ │ │ ├── java
│ │ │ └── com
│ │ │ │ └── example
│ │ │ │ ├── MainActivity.java
│ │ │ │ └── MainApplication.java
│ │ │ └── res
│ │ │ ├── mipmap-hdpi
│ │ │ ├── ic_launcher.png
│ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-mdpi
│ │ │ ├── ic_launcher.png
│ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xhdpi
│ │ │ ├── ic_launcher.png
│ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xxhdpi
│ │ │ ├── ic_launcher.png
│ │ │ └── ic_launcher_round.png
│ │ │ ├── mipmap-xxxhdpi
│ │ │ ├── ic_launcher.png
│ │ │ └── ic_launcher_round.png
│ │ │ └── values
│ │ │ ├── strings.xml
│ │ │ └── styles.xml
│ ├── build.gradle
│ ├── gradle.properties
│ ├── gradle
│ │ └── wrapper
│ │ │ ├── gradle-wrapper.jar
│ │ │ └── gradle-wrapper.properties
│ ├── gradlew
│ ├── gradlew.bat
│ ├── keystores
│ │ ├── BUCK
│ │ └── debug.keystore.properties
│ └── settings.gradle
├── app.json
├── index.js
├── ios
│ ├── example-tvOS
│ │ └── Info.plist
│ ├── example-tvOSTests
│ │ └── Info.plist
│ ├── example.xcodeproj
│ │ ├── project.pbxproj
│ │ └── xcshareddata
│ │ │ └── xcschemes
│ │ │ ├── example-tvOS.xcscheme
│ │ │ └── example.xcscheme
│ ├── example
│ │ ├── AppDelegate.h
│ │ ├── AppDelegate.m
│ │ ├── Base.lproj
│ │ │ └── LaunchScreen.xib
│ │ ├── Images.xcassets
│ │ │ ├── AppIcon.appiconset
│ │ │ │ └── Contents.json
│ │ │ └── Contents.json
│ │ ├── Info.plist
│ │ └── main.m
│ └── exampleTests
│ │ ├── Info.plist
│ │ └── exampleTests.m
├── package.json
├── rnds-demo.gif
├── src
│ ├── colors.js
│ ├── components
│ │ ├── ColumnLabels.js
│ │ ├── Grid.js
│ │ ├── GridContent.js
│ │ └── RowLabels.js
│ └── data.js
└── yarn.lock
├── index.js
├── ios
├── RCTDirectedScrollView.xcodeproj
│ ├── project.pbxproj
│ └── project.xcworkspace
│ │ └── contents.xcworkspacedata
└── RCTDirectedScrollView
│ ├── DirectedScrollViewChildManager.h
│ ├── DirectedScrollViewChildManager.m
│ ├── DirectedScrollViewManager.h
│ └── DirectedScrollViewManager.m
├── package.json
├── react-native-directed-scrollview.podspec
└── yarn.lock
/.gitignore:
--------------------------------------------------------------------------------
1 | ############
2 | # Node
3 | ############
4 | # Logs
5 | logs
6 | *.log
7 | npm-debug.log*
8 |
9 | # Runtime data
10 | pids
11 | *.pid
12 | *.seed
13 |
14 | # Directory for instrumented libs generated by jscoverage/JSCover
15 | lib-cov
16 |
17 | # Coverage directory used by tools like istanbul
18 | coverage
19 |
20 | # nyc test coverage
21 | .nyc_output
22 |
23 | # Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
24 | .grunt
25 |
26 | # node-waf configuration
27 | .lock-wscript
28 |
29 | # Compiled binary addons (http://nodejs.org/api/addons.html)
30 | build/Release
31 |
32 | # Dependency directories
33 | node_modules
34 | jspm_packages
35 |
36 | # Optional npm cache directory
37 | .npm
38 |
39 | # Optional REPL history
40 | .node_repl_history
41 |
42 | ################
43 | # JetBrains
44 | ################
45 | .idea
46 |
47 | ## File-based project format:
48 | *.iws
49 |
50 | ## Plugin-specific files:
51 |
52 | # IntelliJ
53 | /out/
54 |
55 | # mpeltonen/sbt-idea plugin
56 | .idea_modules/
57 |
58 | # JIRA plugin
59 | atlassian-ide-plugin.xml
60 |
61 | # Crashlytics plugin (for Android Studio and IntelliJ)
62 | com_crashlytics_export_strings.xml
63 | crashlytics.properties
64 | crashlytics-build.properties
65 | fabric.properties
66 |
67 |
68 | ############
69 | # iOS
70 | ############
71 | # Xcode
72 | #
73 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
74 |
75 | ## Build generated
76 | ios/build/
77 | ios/DerivedData/
78 |
79 | ## Various settings
80 | *.pbxuser
81 | !default.pbxuser
82 | *.mode1v3
83 | !default.mode1v3
84 | *.mode2v3
85 | !default.mode2v3
86 | *.perspectivev3
87 | !default.perspectivev3
88 | ios/xcuserdata/
89 |
90 | ## Other
91 | *.moved-aside
92 | *.xcuserstate
93 |
94 | ## Obj-C/Swift specific
95 | *.hmap
96 | *.ipa
97 | *.dSYM.zip
98 | *.dSYM
99 |
100 | # CocoaPods
101 | #
102 | # We recommend against adding the Pods directory to your .gitignore. However
103 | # you should judge for yourself, the pros and cons are mentioned at:
104 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
105 | #
106 | ios/Pods/
107 |
108 | # Carthage
109 | #
110 | # Add this line if you want to avoid checking in source code from Carthage dependencies.
111 | # Carthage/Checkouts
112 |
113 | Carthage/Build
114 |
115 | # fastlane
116 | #
117 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
118 | # screenshots whenever they are needed.
119 | # For more information about the recommended setup visit:
120 | # https://github.com/fastlane/fastlane/blob/master/fastlane/docs/Gitignore.md
121 |
122 | fastlane/report.xml
123 | fastlane/screenshots
124 |
125 |
126 | ############
127 | # Android
128 | ############
129 | # Built application files
130 | *.apk
131 | *.ap_
132 |
133 | # Files for the Dalvik VM
134 | *.dex
135 |
136 | # Java class files
137 | *.class
138 |
139 | # Generated files
140 | android/bin/
141 | android/gen/
142 | android/out/
143 |
144 | # Gradle files
145 | android/.gradle/
146 | android/build/
147 |
148 | # Local configuration file (sdk path, etc)
149 | local.properties
150 |
151 | # Proguard folder generated by Eclipse
152 | android/proguard/
153 |
154 | # Log Files
155 | *.log
156 |
157 | # Android Studio Navigation editor temp files
158 | android/.navigation/
159 |
160 | # Android Studio captures folder
161 | android/captures/
162 |
163 | # Intellij
164 | *.iml
165 |
166 | # Keystore files
167 | *.jks
168 |
169 | ##################
170 | # React-Native
171 | ##################
172 | # OSX
173 | #
174 | .DS_Store
175 |
176 | # Xcode
177 | #
178 | build/
179 | *.pbxuser
180 | !default.pbxuser
181 | *.mode1v3
182 | !default.mode1v3
183 | *.mode2v3
184 | !default.mode2v3
185 | *.perspectivev3
186 | !default.perspectivev3
187 | xcuserdata
188 | *.xccheckout
189 | *.moved-aside
190 | DerivedData
191 | *.hmap
192 | *.ipa
193 | *.xcuserstate
194 | project.xcworkspace
195 |
196 | # Android/IJ
197 | #
198 | .idea
199 | .gradle
200 | local.properties
201 |
202 | # node.js
203 | #
204 | node_modules/
205 | npm-debug.log
206 |
207 | # BUCK
208 | buck-out/
209 | \.buckd/
210 | android/app/libs
211 | android/keystores/debug.keystore
--------------------------------------------------------------------------------
/.npmignore:
--------------------------------------------------------------------------------
1 | # .npmignore
2 |
3 | /example
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2016 Chris Fisher
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # UNMAINTAINED
2 |
3 | This library is no longer actively maintained and is not guaranteed to work with the latest version of React Native. Feel free to fork the repo and/or adapt the code.
4 |
5 | # react-native-directed-scrollview
6 |
7 | 
8 |
9 | A natively implemented scrollview component which lets you specify different scroll directions for child content.
10 |
11 | The iOS implementation extends the default UIScrollView component, whereas the Android implementation is custom and aims to provide some limited parity with the iOS api.
12 |
13 | The following props are supported:
14 |
15 | | Prop | Default | Description |
16 | | --- | --- | --- |
17 | | `scrollEnabled` | `true` | When false, the view cannot be scrolled via touch interaction. |
18 | | `pinchGestureEnabled` | `true` | When true, ScrollView allows use of pinch gestures to zoom in and out. |
19 | | `minimumZoomScale` | `1.0` | How far the content can zoom out. |
20 | | `maximumZoomScale` | `1.0` | How far the content can zoom in. |
21 | | `bounces` | `true` | Whether content bounces at the limits when scrolling. |
22 | | `bouncesZoom` | `true` | Whether content bounces at the limits when zooming. |
23 | | `alwaysBounceHorizontal` | `false` | When `bounces` is enabled, content will bounce horizontally even if the content is smaller than the bounds of the scroll view. |
24 | | `alwaysBounceVertical` | `false` | When `bounces` is enabled, content will bounce vertically even if the content is smaller than the bounds of the scroll view.. |
25 | | **ios** `showsVerticalScrollIndicator` | `true` | Whether vertical scroll bars are visible. |
26 | | **ios** `showsHorizontalScrollIndicator` | `true` | Whether horizontal scroll bars are visible. |
27 |
28 | The following methods are supported:
29 |
30 | | Method | Example | Description |
31 | | --- | --- | --- |
32 | | `scrollTo` | `scrollTo({x: 100, y: 100, animated: true})` | Scrolls to a given x and y offset. |
33 |
34 | ## Installation
35 |
36 | - `npm install react-native-directed-scrollview --save`
37 | - `react-native link` (or `rnpm link`)
38 |
39 | ## Usage
40 |
41 | To work properly this component requires that a fixed-size content container be specified through the **contentContainerStyle** prop.
42 |
43 | ```javascript
44 | import ScrollView, { ScrollViewChild } from 'react-native-directed-scrollview';
45 | ...
46 |
47 | export default class Example extends Component {
48 | render() {
49 | return (
50 |
60 |
61 | // multi-directional scrolling content here...
62 |
63 |
64 | // vertically scrolling content here...
65 |
66 |
67 | // horizontally scrolling content here...
68 |
69 |
70 | );
71 | }
72 | }
73 |
74 | const styles = StyleSheet.create({
75 | container: {
76 | flex: 1,
77 | },
78 | contentContainer: {
79 | height: 1000,
80 | width: 1000,
81 | },
82 | })
83 | ```
84 |
85 | See the [example project](https://github.com/chrisfisher/react-native-directed-scrollview/tree/master/example) for more detail.
86 |
--------------------------------------------------------------------------------
/android/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: 'com.android.library'
2 |
3 | android {
4 | compileSdkVersion 26
5 | buildToolsVersion "26.0.2"
6 |
7 | defaultConfig {
8 | minSdkVersion 16
9 | targetSdkVersion 22
10 | versionCode 2
11 | versionName "1.1"
12 | ndk {
13 | abiFilters "armeabi-v7a", "x86"
14 | }
15 | }
16 | lintOptions {
17 | warning 'InvalidPackage'
18 | }
19 | }
20 |
21 | dependencies {
22 | compile 'com.facebook.react:react-native:+'
23 | }
24 |
--------------------------------------------------------------------------------
/android/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
--------------------------------------------------------------------------------
/android/src/main/java/com/rnds/DirectedScrollView.java:
--------------------------------------------------------------------------------
1 | package com.rnds;
2 |
3 | import android.animation.ObjectAnimator;
4 | import android.content.Context;
5 | import android.graphics.Matrix;
6 | import android.support.v4.view.animation.FastOutLinearInInterpolator;
7 | import android.view.MotionEvent;
8 | import android.view.View;
9 | import android.view.ViewConfiguration;
10 | import android.view.ViewParent;
11 | import android.view.ScaleGestureDetector;
12 | import android.view.animation.Interpolator;
13 |
14 | import com.facebook.react.views.scroll.ScrollEventType;
15 | import com.facebook.react.views.scroll.ScrollEvent;
16 | import com.facebook.react.uimanager.PixelUtil;
17 | import com.facebook.react.uimanager.events.NativeGestureUtil;
18 | import com.facebook.react.uimanager.UIManagerModule;
19 | import com.facebook.react.views.scroll.ReactScrollViewHelper;
20 | import com.facebook.react.views.view.ReactViewGroup;
21 | import com.facebook.react.bridge.ReactContext;
22 |
23 | import java.util.ArrayList;
24 | import java.util.List;
25 |
26 | public class DirectedScrollView extends ReactViewGroup {
27 |
28 | private static final long SNAP_BACK_ANIMATION_DURATION = 120;
29 | private static final Interpolator SNAP_BACK_ANIMATION_INTERPOLATOR = new FastOutLinearInInterpolator();
30 |
31 | private float minimumZoomScale = 1.0f;
32 | private float maximumZoomScale = 1.0f;
33 | private boolean bounces = true;
34 | private boolean alwaysBounceVertical = false;
35 | private boolean alwaysBounceHorizontal = false;
36 | private boolean bouncesZoom = true;
37 | private boolean scrollEnabled = true;
38 | private boolean pinchGestureEnabled = true;
39 |
40 | private float pivotX;
41 | private float pivotY;
42 | private float scrollX;
43 | private float scrollY;
44 | private float startScrollX;
45 | private float startScrollY;
46 | private float startTouchX;
47 | private float startTouchY;
48 | private float scaleFactor = 1.0f;
49 | private boolean isScaleInProgress;
50 | private boolean isScrollInProgress;
51 | private float touchSlop;
52 | private float lastPositionX, lastPositionY;
53 | private boolean isDragging;
54 |
55 | private ScaleGestureDetector scaleDetector;
56 |
57 | private ReactContext reactContext;
58 |
59 | public DirectedScrollView(Context context) {
60 | super(context);
61 |
62 | initPinchGestureListeners(context);
63 | reactContext = (ReactContext)this.getContext();
64 | touchSlop = ViewConfiguration.get(context).getScaledTouchSlop();
65 | }
66 |
67 | @Override
68 | protected void onAttachedToWindow() {
69 | super.onAttachedToWindow();
70 |
71 | anchorChildren();
72 | }
73 |
74 | @Override
75 | public boolean onInterceptTouchEvent(final MotionEvent motionEvent) {
76 | if (!scrollEnabled) {
77 | return false;
78 | }
79 |
80 | emitScrollEvent(ScrollEventType.BEGIN_DRAG, 0, 0);
81 |
82 | int action = motionEvent.getAction();
83 | if (action == MotionEvent.ACTION_UP | action == MotionEvent.ACTION_CANCEL) {
84 | isScrollInProgress = false;
85 | isScaleInProgress = false;
86 | return false;
87 | }
88 |
89 | if (action == MotionEvent.ACTION_MOVE & isDragging) {
90 | return true;
91 | }
92 |
93 | if (super.onInterceptTouchEvent(motionEvent)) {
94 | return true;
95 | }
96 |
97 | switch (action) {
98 | case MotionEvent.ACTION_DOWN:
99 | lastPositionX = motionEvent.getX();
100 | lastPositionY = motionEvent.getY();
101 | onActionDown(motionEvent);
102 | break;
103 | case MotionEvent.ACTION_POINTER_DOWN:
104 | onActionPointerDown();
105 | break;
106 | case MotionEvent.ACTION_MOVE:
107 | float diffX = Math.abs(motionEvent.getX() - lastPositionX);
108 | float diffY = Math.abs(motionEvent.getY() - lastPositionY);
109 | if (isScaleInProgress || diffX > touchSlop || diffY > touchSlop) {
110 | lastPositionX = motionEvent.getX();
111 | lastPositionY = motionEvent.getY();
112 | disallowInterceptTouchEventsForParent();
113 | return true;
114 | }
115 | break;
116 | }
117 |
118 |
119 | return false;
120 | }
121 |
122 | @Override
123 | public boolean onTouchEvent(MotionEvent motionEvent) {
124 | switch (motionEvent.getAction()) {
125 | case MotionEvent.ACTION_DOWN:
126 | onActionDown(motionEvent);
127 | break;
128 | case MotionEvent.ACTION_POINTER_DOWN:
129 | onActionPointerDown();
130 | break;
131 | case MotionEvent.ACTION_MOVE:
132 | onActionMove(motionEvent);
133 | break;
134 | case MotionEvent.ACTION_UP:
135 | onActionUp();
136 | break;
137 | }
138 |
139 | scaleDetector.onTouchEvent(motionEvent);
140 |
141 | return true;
142 |
143 | }
144 |
145 | private void disallowInterceptTouchEventsForParent() {
146 | ViewParent parent = getParent();
147 | if (parent != null) {
148 | parent.requestDisallowInterceptTouchEvent(true);
149 | }
150 | }
151 |
152 | private void initPinchGestureListeners(Context context) {
153 | scaleDetector = new ScaleGestureDetector(context, new ScaleGestureDetector.SimpleOnScaleGestureListener() {
154 |
155 | @Override
156 | public boolean onScaleBegin(ScaleGestureDetector detector) {
157 | float x = detector.getFocusX();
158 | float y = detector.getFocusY();
159 | pivotChildren(x, y);
160 | updateChildren();
161 | return true;
162 | }
163 |
164 | @Override
165 | public boolean onScale(ScaleGestureDetector detector) {
166 | if (!pinchGestureEnabled) {
167 | return false;
168 | }
169 |
170 | scaleFactor *= detector.getScaleFactor();
171 | updateChildren();
172 | return true;
173 | }
174 |
175 | private void updateChildren() {
176 | if (bouncesZoom) {
177 | scaleChildren(false);
178 | } else {
179 | clampAndScaleChildren(false);
180 | }
181 |
182 | if (bounces) {
183 | translateChildren(false);
184 | } else {
185 | clampAndTranslateChildren(false);
186 | }
187 | invalidate();
188 | }
189 | });
190 | }
191 |
192 | private void onActionDown(MotionEvent motionEvent) {
193 | startTouchX = motionEvent.getX();
194 | startTouchY = motionEvent.getY();
195 | startScrollX = scrollX;
196 | startScrollY = scrollY;
197 | }
198 |
199 | private void onActionPointerDown() {
200 | isScaleInProgress = true;
201 | }
202 |
203 | private void onActionMove(MotionEvent motionEvent) {
204 | NativeGestureUtil.notifyNativeGestureStarted(this, motionEvent);
205 |
206 | if (isScaleInProgress) return;
207 |
208 | isScrollInProgress = true;
209 |
210 | float deltaX = motionEvent.getX() - startTouchX;
211 | float deltaY = motionEvent.getY() - startTouchY;
212 |
213 | scrollX = startScrollX + deltaX;
214 | scrollY = startScrollY + deltaY;
215 |
216 | if (bounces) {
217 | clampAndTranslateChildren(false, getMaxScrollY() <= 0 && !alwaysBounceVertical, getMaxScrollX() <= 0 && !alwaysBounceHorizontal);
218 | } else {
219 | clampAndTranslateChildren(false);
220 | }
221 |
222 | this.emitScrollEvent(ScrollEventType.SCROLL, deltaX * -1, deltaY * -1);
223 | }
224 |
225 | private void onActionUp() {
226 | if (isScrollInProgress) {
227 | emitScrollEvent(ScrollEventType.END_DRAG, 0, 0);
228 | isScrollInProgress = false;
229 | }
230 |
231 | if (bounces) {
232 | clampAndTranslateChildren(true);
233 | }
234 |
235 | if (bouncesZoom) {
236 | clampAndScaleChildren(true);
237 | }
238 |
239 | isScaleInProgress = false;
240 | }
241 | private void clampAndTranslateChildren(boolean animated) {
242 | this.clampAndTranslateChildren(animated, true, true);
243 | }
244 |
245 | private void clampAndTranslateChildren(boolean animated, boolean clampVertical, boolean clampHorizontal) {
246 | float[] minPoints = transformPoints(new float[] { 0, 0 });
247 | float minX = minPoints[0];
248 | float minY = minPoints[1];
249 | float maxX = minPoints[0] + getMaxScrollX();
250 | float maxY = minPoints[1] + getMaxScrollY();
251 |
252 | if (clampHorizontal) {
253 | if (maxX > minX) {
254 | scrollX = clamp(scrollX, -maxX, -minX);
255 | } else {
256 | scrollX = -minX;
257 | }
258 | }
259 | if (clampVertical) {
260 | if (maxY > minY) {
261 | scrollY = clamp(scrollY, -maxY, -minY);
262 | } else {
263 | scrollY = -minY;
264 | }
265 | }
266 | translateChildren(animated);
267 | }
268 |
269 | private void clampAndScaleChildren(boolean animated) {
270 | scaleFactor = clamp(scaleFactor, minimumZoomScale, maximumZoomScale);
271 |
272 | scaleChildren(animated);
273 | }
274 |
275 | private void scaleChildren(boolean animated) {
276 | List scrollableChildren = getScrollableChildren();
277 |
278 | for (DirectedScrollViewChild scrollableChild : scrollableChildren) {
279 | if (animated) {
280 | animateProperty(scrollableChild, "scaleX", scrollableChild.getScaleX(), scaleFactor);
281 | animateProperty(scrollableChild, "scaleY", scrollableChild.getScaleY(), scaleFactor);
282 | } else {
283 | scrollableChild.setScaleX(scaleFactor);
284 | scrollableChild.setScaleY(scaleFactor);
285 | }
286 | }
287 | }
288 |
289 | private void translateChildren(boolean animated) {
290 | List scrollableChildren = getScrollableChildren();
291 |
292 | for (DirectedScrollViewChild scrollableChild : scrollableChildren) {
293 | if (scrollableChild.getShouldScrollHorizontally()) {
294 | if (animated) {
295 | animateProperty(scrollableChild, "translationX", scrollableChild.getTranslationX(), scrollX);
296 | } else {
297 | scrollableChild.setTranslationX(scrollX);
298 | }
299 | }
300 |
301 | if (scrollableChild.getShouldScrollVertically()) {
302 | if (animated) {
303 | animateProperty(scrollableChild, "translationY", scrollableChild.getTranslationY(), scrollY);
304 | } else {
305 | scrollableChild.setTranslationY(scrollY);
306 | }
307 | }
308 | }
309 | }
310 |
311 | private void pivotChildren(float newPivotX, float newPivotY) {
312 | float oldPivotX = pivotX;
313 | float oldPivotY = pivotY;
314 | pivotX = newPivotX - scrollX;
315 | pivotY = newPivotY - scrollY;
316 |
317 | scrollX += (oldPivotX - pivotX) * (1 - scaleFactor);
318 | scrollY += (oldPivotY - pivotY) * (1 - scaleFactor);
319 |
320 | List scrollableChildren = getScrollableChildren();
321 | for (DirectedScrollViewChild scrollableChild : scrollableChildren) {
322 | if (scrollableChild.getShouldScrollHorizontally()) {
323 | scrollableChild.setTranslationX(scrollX);
324 | scrollableChild.setPivotX(pivotX);
325 | }
326 | if (scrollableChild.getShouldScrollVertically()) {
327 | scrollableChild.setTranslationY(scrollY);
328 | scrollableChild.setPivotY(pivotY);
329 | }
330 | }
331 | }
332 |
333 | private void anchorChildren() {
334 | List scrollableChildren = getScrollableChildren();
335 |
336 | for (DirectedScrollViewChild scrollableChild : scrollableChildren) {
337 | scrollableChild.setPivotY(0);
338 | scrollableChild.setPivotX(0);
339 | }
340 | }
341 |
342 | private float[] transformPoints(float[] points) {
343 | float[] transformedPoints = new float[points.length];
344 |
345 | Matrix matrix = new Matrix();
346 | matrix.setScale(scaleFactor, scaleFactor, pivotX, pivotY);
347 | matrix.mapPoints(transformedPoints, points);
348 |
349 | return transformedPoints;
350 | }
351 |
352 | private void animateProperty(Object target, String property, float start, float end) {
353 | if (start == end) return;
354 |
355 | ObjectAnimator anim = ObjectAnimator.ofFloat(target, property, start, end);
356 | anim.setDuration(SNAP_BACK_ANIMATION_DURATION);
357 | anim.setInterpolator(SNAP_BACK_ANIMATION_INTERPOLATOR);
358 | anim.start();
359 | }
360 |
361 | private float clamp(float value, float min, float max) {
362 | return Math.max(min, Math.min(value, max));
363 | }
364 |
365 | private float getContentContainerWidth() {
366 | return getChildAt(0).getWidth() * scaleFactor;
367 | }
368 |
369 | private float getContentContainerHeight() {
370 | return getChildAt(0).getHeight() * scaleFactor;
371 | }
372 |
373 | private float getMaxScrollX() {
374 | return getContentContainerWidth() - getWidth();
375 | }
376 |
377 | private float getMaxScrollY() {
378 | return getContentContainerHeight() - getHeight();
379 | }
380 |
381 | private ArrayList getScrollableChildren() {
382 | ArrayList scrollableChildren = new ArrayList<>();
383 |
384 | for (int i = 0; i < getChildCount(); i++) {
385 | View childView = getChildAt(i);
386 |
387 | if (childView instanceof DirectedScrollViewChild) {
388 | scrollableChildren.add((DirectedScrollViewChild) childView);
389 | }
390 | }
391 |
392 | return scrollableChildren;
393 | }
394 |
395 | private void emitScrollEvent(
396 | ScrollEventType scrollEventType,
397 | float xVelocity,
398 | float yVelocity) {
399 | reactContext.getNativeModule(UIManagerModule.class).getEventDispatcher().dispatchEvent(
400 | ScrollEvent.obtain(
401 | getId(),
402 | scrollEventType,
403 | Math.round(scrollX * -1),
404 | Math.round(scrollY * -1),
405 | xVelocity,
406 | yVelocity,
407 | Math.round(getContentContainerWidth()),
408 | Math.round(getContentContainerHeight()),
409 | getWidth(),
410 | getHeight()));
411 | }
412 |
413 | public void setMaximumZoomScale(final float maximumZoomScale) {
414 | this.maximumZoomScale = maximumZoomScale;
415 | }
416 |
417 | public void setMinimumZoomScale(final float minimumZoomScale) {
418 | this.minimumZoomScale = minimumZoomScale;
419 | }
420 |
421 | public void setPinchGestureEnabled(final boolean pinchGestureEnabled) {
422 | this.pinchGestureEnabled = pinchGestureEnabled;
423 | }
424 | public void setScrollEnabled(final boolean scrollEnabled) {
425 | this.scrollEnabled = scrollEnabled;
426 | }
427 |
428 | public void setBounces(final boolean bounces) {
429 | this.bounces = bounces;
430 | }
431 |
432 | public void setBouncesZoom(final boolean bouncesZoom) {
433 | this.bouncesZoom = bouncesZoom;
434 | }
435 |
436 | public void setAlwaysBounceHorizontal(final boolean alwaysBounceHorizontal) {
437 | this.alwaysBounceHorizontal = alwaysBounceHorizontal;
438 | }
439 |
440 | public void setAlwaysBounceVertical(final boolean alwaysBounceVertical) {
441 | this.alwaysBounceVertical = alwaysBounceVertical;
442 | }
443 |
444 | public void scrollTo(Double x, Double y, Boolean animated) {
445 | float convertedX = PixelUtil.toPixelFromDIP(x);
446 | float convertedY = PixelUtil.toPixelFromDIP(y);
447 | scrollX = -convertedX;
448 | scrollY = -convertedY;
449 |
450 | translateChildren(animated);
451 | }
452 | }
453 |
--------------------------------------------------------------------------------
/android/src/main/java/com/rnds/DirectedScrollViewChild.java:
--------------------------------------------------------------------------------
1 | package com.rnds;
2 |
3 | import android.content.Context;
4 |
5 | import com.facebook.common.internal.Objects;
6 | import com.facebook.react.views.view.ReactViewGroup;
7 |
8 | public class DirectedScrollViewChild extends ReactViewGroup {
9 |
10 | private static final String SCROLL_DIRECTION_BOTH = "both";
11 | private static final String SCROLL_DIRECTION_HORIZONTAL = "horizontal";
12 | private static final String SCROLL_DIRECTION_VERTICAL = "vertical";
13 |
14 | private String scrollDirection;
15 |
16 | public DirectedScrollViewChild(Context context) {
17 | super(context);
18 | }
19 |
20 | public boolean getShouldScrollHorizontally() {
21 | return Objects.equal(this.scrollDirection, SCROLL_DIRECTION_BOTH) || Objects.equal(this.scrollDirection, SCROLL_DIRECTION_HORIZONTAL);
22 | }
23 |
24 | public boolean getShouldScrollVertically() {
25 | return Objects.equal(this.scrollDirection, SCROLL_DIRECTION_BOTH) || Objects.equal(this.scrollDirection, SCROLL_DIRECTION_VERTICAL);
26 | }
27 |
28 | public void setScrollDirection(final String scrollDirection) {
29 | this.scrollDirection = scrollDirection;
30 | }
31 | }
32 |
--------------------------------------------------------------------------------
/android/src/main/java/com/rnds/DirectedScrollViewChildManager.java:
--------------------------------------------------------------------------------
1 | package com.rnds;
2 |
3 | import android.support.annotation.Nullable;
4 |
5 | import com.facebook.react.uimanager.ThemedReactContext;
6 | import com.facebook.react.uimanager.ViewGroupManager;
7 | import com.facebook.react.uimanager.annotations.ReactProp;
8 |
9 | public class DirectedScrollViewChildManager extends ViewGroupManager {
10 |
11 | @Override
12 | public String getName() {
13 | return "DirectedScrollViewChild";
14 | }
15 |
16 | @Override
17 | public DirectedScrollViewChild createViewInstance(ThemedReactContext context) {
18 | return new DirectedScrollViewChild(context);
19 | }
20 |
21 | @ReactProp(name = "scrollDirection", customType = "none")
22 | public void setScrollDirection (DirectedScrollViewChild view, @Nullable String scrollDirection) {
23 | view.setScrollDirection(scrollDirection);
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/android/src/main/java/com/rnds/DirectedScrollViewManager.java:
--------------------------------------------------------------------------------
1 | package com.rnds;
2 |
3 | import android.support.annotation.Nullable;
4 |
5 | import com.facebook.react.uimanager.ThemedReactContext;
6 | import com.facebook.react.uimanager.ViewGroupManager;
7 | import com.facebook.react.uimanager.annotations.ReactProp;
8 | import com.facebook.react.bridge.ReadableArray;
9 | import com.facebook.react.common.MapBuilder;
10 | import com.facebook.react.views.scroll.ScrollEventType;
11 |
12 | import java.util.Map;
13 |
14 | class DirectedScrollViewManager extends ViewGroupManager {
15 |
16 | public static final int COMMAND_SCROLL_TO = 1;
17 | public static final int COMMAND_ZOOM_TO_START = 2;
18 |
19 | @Override
20 | public String getName() {
21 | return "DirectedScrollView";
22 | }
23 |
24 | @Override
25 | public DirectedScrollView createViewInstance(ThemedReactContext context) {
26 | return new DirectedScrollView(context);
27 | }
28 |
29 | @Override
30 | public Map getCommandsMap() {
31 | return MapBuilder.of(
32 | "scrollTo", COMMAND_SCROLL_TO,
33 | "zoomToStart", COMMAND_ZOOM_TO_START
34 | );
35 | }
36 |
37 | @Override
38 | public void receiveCommand(DirectedScrollView view, int commandType, @Nullable ReadableArray args) {
39 | super.receiveCommand(view, commandType, args);
40 |
41 | switch (commandType) {
42 | case COMMAND_SCROLL_TO:
43 | Double translateX = args.getDouble(0);
44 | Double translateY = args.getDouble(1);
45 | Boolean animated = args.getBoolean(2);
46 |
47 | view.scrollTo(translateX, translateY, animated);
48 | break;
49 | case COMMAND_ZOOM_TO_START:
50 | view.scrollTo(0.0, 0.0, args.getBoolean(0));
51 | break;
52 | default:
53 | throw new IllegalArgumentException(String.format("Unsupported command %d received by %s.", commandType, getClass().getSimpleName()));
54 | }
55 | }
56 |
57 | @Override
58 | public @Nullable Map getExportedCustomDirectEventTypeConstants() {
59 | return createExportedCustomDirectEventTypeConstants();
60 | }
61 |
62 | public static Map createExportedCustomDirectEventTypeConstants() {
63 | return MapBuilder.builder()
64 | .put(ScrollEventType.getJSEventName(ScrollEventType.SCROLL), MapBuilder.of("registrationName", "onScroll"))
65 | .put(ScrollEventType.getJSEventName(ScrollEventType.BEGIN_DRAG), MapBuilder.of("registrationName", "onScrollBeginDrag"))
66 | .put(ScrollEventType.getJSEventName(ScrollEventType.END_DRAG), MapBuilder.of("registrationName", "onScrollEndDrag"))
67 | .put(ScrollEventType.getJSEventName(ScrollEventType.MOMENTUM_BEGIN), MapBuilder.of("registrationName", "onMomentumScrollBegin"))
68 | .put(ScrollEventType.getJSEventName(ScrollEventType.MOMENTUM_END), MapBuilder.of("registrationName", "onMomentumScrollEnd"))
69 | .build();
70 | }
71 |
72 | @ReactProp(name = "minimumZoomScale", defaultFloat = 1.0f)
73 | public void setMinimumZoomScale(DirectedScrollView view, @Nullable float minimumZoomScale) {
74 | view.setMinimumZoomScale(minimumZoomScale);
75 | }
76 |
77 | @ReactProp(name = "maximumZoomScale", defaultFloat = 1.0f)
78 | public void setMaximumZoomScale(DirectedScrollView view, @Nullable float maximumZoomScale) {
79 | view.setMaximumZoomScale(maximumZoomScale);
80 | }
81 |
82 | @ReactProp(name = "bounces", defaultBoolean = true)
83 | public void setBounces(DirectedScrollView view, @Nullable boolean bounces) {
84 | view.setBounces(bounces);
85 | }
86 |
87 | @ReactProp(name = "bouncesZoom", defaultBoolean = true)
88 | public void setBouncesZoom(DirectedScrollView view, @Nullable boolean bouncesZoom) {
89 | view.setBouncesZoom(bouncesZoom);
90 | }
91 |
92 | @ReactProp(name = "alwaysBounceHorizontal", defaultBoolean = false)
93 | public void setAlwaysBounceHorizontal(DirectedScrollView view, @Nullable boolean alwaysBounceHorizontal) {
94 | view.setAlwaysBounceHorizontal(alwaysBounceHorizontal);
95 | }
96 |
97 | @ReactProp(name = "alwaysBounceVertical", defaultBoolean = false)
98 | public void setAlwaysBounceVertical(DirectedScrollView view, @Nullable boolean alwaysBounceVertical) {
99 | view.setAlwaysBounceVertical(alwaysBounceVertical);
100 | }
101 |
102 | @ReactProp(name = "scrollEnabled", defaultBoolean = true)
103 | public void setScrollEnabled(DirectedScrollView view, @Nullable boolean scrollEnabled) {
104 | view.setScrollEnabled(scrollEnabled);
105 | }
106 |
107 | @ReactProp(name = "pinchGestureEnabled", defaultBoolean = true)
108 | public void setPinchGestureEnabled(DirectedScrollView view, @Nullable boolean pinchGestureEnabled) {
109 | view.setPinchGestureEnabled(pinchGestureEnabled);
110 | }
111 | }
112 |
--------------------------------------------------------------------------------
/android/src/main/java/com/rnds/DirectedScrollViewPackage.java:
--------------------------------------------------------------------------------
1 | package com.rnds;
2 |
3 | import java.util.ArrayList;
4 | import java.util.Collections;
5 | import java.util.List;
6 |
7 | import com.facebook.react.ReactPackage;
8 | import com.facebook.react.bridge.NativeModule;
9 | import com.facebook.react.bridge.ReactApplicationContext;
10 | import com.facebook.react.uimanager.ViewManager;
11 | import com.facebook.react.bridge.JavaScriptModule;
12 |
13 | public class DirectedScrollViewPackage implements ReactPackage {
14 |
15 | @Override
16 | public List createNativeModules(ReactApplicationContext reactApplicationContext) {
17 | return Collections.emptyList();
18 | }
19 |
20 | @Override
21 | public List createViewManagers(ReactApplicationContext reactApplicationContext) {
22 | ArrayList viewManagers = new ArrayList();
23 | viewManagers.add(new DirectedScrollViewManager());
24 | viewManagers.add(new DirectedScrollViewChildManager());
25 | return viewManagers;
26 | }
27 | }
28 |
--------------------------------------------------------------------------------
/example/.babelrc:
--------------------------------------------------------------------------------
1 | {
2 | "presets": ["module:metro-react-native-babel-preset"]
3 | }
4 |
--------------------------------------------------------------------------------
/example/.buckconfig:
--------------------------------------------------------------------------------
1 |
2 | [android]
3 | target = Google Inc.:Google APIs:23
4 |
5 | [maven_repositories]
6 | central = https://repo1.maven.org/maven2
7 |
--------------------------------------------------------------------------------
/example/.flowconfig:
--------------------------------------------------------------------------------
1 | [ignore]
2 | ; We fork some components by platform
3 | .*/*[.]android.js
4 |
5 | ; Ignore "BUCK" generated dirs
6 | /\.buckd/
7 |
8 | ; Ignore unexpected extra "@providesModule"
9 | .*/node_modules/.*/node_modules/fbjs/.*
10 |
11 | ; Ignore duplicate module providers
12 | ; For RN Apps installed via npm, "Libraries" folder is inside
13 | ; "node_modules/react-native" but in the source repo it is in the root
14 | .*/Libraries/react-native/React.js
15 |
16 | ; Ignore polyfills
17 | .*/Libraries/polyfills/.*
18 |
19 | ; Ignore metro
20 | .*/node_modules/metro/.*
21 |
22 | [include]
23 |
24 | [libs]
25 | node_modules/react-native/Libraries/react-native/react-native-interface.js
26 | node_modules/react-native/flow/
27 | node_modules/react-native/flow-github/
28 |
29 | [options]
30 | emoji=true
31 |
32 | esproposal.optional_chaining=enable
33 | esproposal.nullish_coalescing=enable
34 |
35 | module.system=haste
36 | module.system.haste.use_name_reducers=true
37 | # get basename
38 | module.system.haste.name_reducers='^.*/\([a-zA-Z0-9$_.-]+\.js\(\.flow\)?\)$' -> '\1'
39 | # strip .js or .js.flow suffix
40 | module.system.haste.name_reducers='^\(.*\)\.js\(\.flow\)?$' -> '\1'
41 | # strip .ios suffix
42 | module.system.haste.name_reducers='^\(.*\)\.ios$' -> '\1'
43 | module.system.haste.name_reducers='^\(.*\)\.android$' -> '\1'
44 | module.system.haste.name_reducers='^\(.*\)\.native$' -> '\1'
45 | module.system.haste.paths.blacklist=.*/__tests__/.*
46 | module.system.haste.paths.blacklist=.*/__mocks__/.*
47 | module.system.haste.paths.blacklist=/node_modules/react-native/Libraries/Animated/src/polyfills/.*
48 | module.system.haste.paths.whitelist=/node_modules/react-native/Libraries/.*
49 |
50 | munge_underscores=true
51 |
52 | module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
53 |
54 | module.file_ext=.js
55 | module.file_ext=.jsx
56 | module.file_ext=.json
57 | module.file_ext=.native.js
58 |
59 | suppress_type=$FlowIssue
60 | suppress_type=$FlowFixMe
61 | suppress_type=$FlowFixMeProps
62 | suppress_type=$FlowFixMeState
63 |
64 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
65 | suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
66 | suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
67 | suppress_comment=\\(.\\|\n\\)*\\$FlowExpectedError
68 |
69 | [version]
70 | ^0.78.0
71 |
--------------------------------------------------------------------------------
/example/.gitattributes:
--------------------------------------------------------------------------------
1 | *.pbxproj -text
2 |
--------------------------------------------------------------------------------
/example/.gitignore:
--------------------------------------------------------------------------------
1 | # OSX
2 | #
3 | .DS_Store
4 |
5 | # Xcode
6 | #
7 | build/
8 | *.pbxuser
9 | !default.pbxuser
10 | *.mode1v3
11 | !default.mode1v3
12 | *.mode2v3
13 | !default.mode2v3
14 | *.perspectivev3
15 | !default.perspectivev3
16 | xcuserdata
17 | *.xccheckout
18 | *.moved-aside
19 | DerivedData
20 | *.hmap
21 | *.ipa
22 | *.xcuserstate
23 | project.xcworkspace
24 |
25 | # Android/IntelliJ
26 | #
27 | build/
28 | .idea
29 | .gradle
30 | local.properties
31 | *.iml
32 |
33 | # node.js
34 | #
35 | node_modules/
36 | npm-debug.log
37 | yarn-error.log
38 |
39 | # BUCK
40 | buck-out/
41 | \.buckd/
42 | *.keystore
43 |
44 | # fastlane
45 | #
46 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47 | # screenshots whenever they are needed.
48 | # For more information about the recommended setup visit:
49 | # https://docs.fastlane.tools/best-practices/source-control/
50 |
51 | */fastlane/report.xml
52 | */fastlane/Preview.html
53 | */fastlane/screenshots
54 |
55 | # Bundle artifact
56 | *.jsbundle
57 |
--------------------------------------------------------------------------------
/example/.watchmanconfig:
--------------------------------------------------------------------------------
1 | {}
--------------------------------------------------------------------------------
/example/android/app/BUCK:
--------------------------------------------------------------------------------
1 | # To learn about Buck see [Docs](https://buckbuild.com/).
2 | # To run your application with Buck:
3 | # - install Buck
4 | # - `npm start` - to start the packager
5 | # - `cd android`
6 | # - `keytool -genkey -v -keystore keystores/debug.keystore -storepass android -alias androiddebugkey -keypass android -dname "CN=Android Debug,O=Android,C=US"`
7 | # - `./gradlew :app:copyDownloadableDepsToLibs` - make all Gradle compile dependencies available to Buck
8 | # - `buck install -r android/app` - compile, install and run application
9 | #
10 |
11 | lib_deps = []
12 |
13 | for jarfile in glob(['libs/*.jar']):
14 | name = 'jars__' + jarfile[jarfile.rindex('/') + 1: jarfile.rindex('.jar')]
15 | lib_deps.append(':' + name)
16 | prebuilt_jar(
17 | name = name,
18 | binary_jar = jarfile,
19 | )
20 |
21 | for aarfile in glob(['libs/*.aar']):
22 | name = 'aars__' + aarfile[aarfile.rindex('/') + 1: aarfile.rindex('.aar')]
23 | lib_deps.append(':' + name)
24 | android_prebuilt_aar(
25 | name = name,
26 | aar = aarfile,
27 | )
28 |
29 | android_library(
30 | name = "all-libs",
31 | exported_deps = lib_deps,
32 | )
33 |
34 | android_library(
35 | name = "app-code",
36 | srcs = glob([
37 | "src/main/java/**/*.java",
38 | ]),
39 | deps = [
40 | ":all-libs",
41 | ":build_config",
42 | ":res",
43 | ],
44 | )
45 |
46 | android_build_config(
47 | name = "build_config",
48 | package = "com.example",
49 | )
50 |
51 | android_resource(
52 | name = "res",
53 | package = "com.example",
54 | res = "src/main/res",
55 | )
56 |
57 | android_binary(
58 | name = "app",
59 | keystore = "//android/keystores:debug",
60 | manifest = "src/main/AndroidManifest.xml",
61 | package_type = "debug",
62 | deps = [
63 | ":app-code",
64 | ],
65 | )
66 |
--------------------------------------------------------------------------------
/example/android/app/build.gradle:
--------------------------------------------------------------------------------
1 | apply plugin: "com.android.application"
2 |
3 | import com.android.build.OutputFile
4 |
5 | /**
6 | * The react.gradle file registers a task for each build variant (e.g. bundleDebugJsAndAssets
7 | * and bundleReleaseJsAndAssets).
8 | * These basically call `react-native bundle` with the correct arguments during the Android build
9 | * cycle. By default, bundleDebugJsAndAssets is skipped, as in debug/dev mode we prefer to load the
10 | * bundle directly from the development server. Below you can see all the possible configurations
11 | * and their defaults. If you decide to add a configuration block, make sure to add it before the
12 | * `apply from: "../../node_modules/react-native/react.gradle"` line.
13 | *
14 | * project.ext.react = [
15 | * // the name of the generated asset file containing your JS bundle
16 | * bundleAssetName: "index.android.bundle",
17 | *
18 | * // the entry file for bundle generation
19 | * entryFile: "index.android.js",
20 | *
21 | * // whether to bundle JS and assets in debug mode
22 | * bundleInDebug: false,
23 | *
24 | * // whether to bundle JS and assets in release mode
25 | * bundleInRelease: true,
26 | *
27 | * // whether to bundle JS and assets in another build variant (if configured).
28 | * // See http://tools.android.com/tech-docs/new-build-system/user-guide#TOC-Build-Variants
29 | * // The configuration property can be in the following formats
30 | * // 'bundleIn${productFlavor}${buildType}'
31 | * // 'bundleIn${buildType}'
32 | * // bundleInFreeDebug: true,
33 | * // bundleInPaidRelease: true,
34 | * // bundleInBeta: true,
35 | *
36 | * // whether to disable dev mode in custom build variants (by default only disabled in release)
37 | * // for example: to disable dev mode in the staging build type (if configured)
38 | * devDisabledInStaging: true,
39 | * // The configuration property can be in the following formats
40 | * // 'devDisabledIn${productFlavor}${buildType}'
41 | * // 'devDisabledIn${buildType}'
42 | *
43 | * // the root of your project, i.e. where "package.json" lives
44 | * root: "../../",
45 | *
46 | * // where to put the JS bundle asset in debug mode
47 | * jsBundleDirDebug: "$buildDir/intermediates/assets/debug",
48 | *
49 | * // where to put the JS bundle asset in release mode
50 | * jsBundleDirRelease: "$buildDir/intermediates/assets/release",
51 | *
52 | * // where to put drawable resources / React Native assets, e.g. the ones you use via
53 | * // require('./image.png')), in debug mode
54 | * resourcesDirDebug: "$buildDir/intermediates/res/merged/debug",
55 | *
56 | * // where to put drawable resources / React Native assets, e.g. the ones you use via
57 | * // require('./image.png')), in release mode
58 | * resourcesDirRelease: "$buildDir/intermediates/res/merged/release",
59 | *
60 | * // by default the gradle tasks are skipped if none of the JS files or assets change; this means
61 | * // that we don't look at files in android/ or ios/ to determine whether the tasks are up to
62 | * // date; if you have any other folders that you want to ignore for performance reasons (gradle
63 | * // indexes the entire tree), add them here. Alternatively, if you have JS files in android/
64 | * // for example, you might want to remove it from here.
65 | * inputExcludes: ["android/**", "ios/**"],
66 | *
67 | * // override which node gets called and with what additional arguments
68 | * nodeExecutableAndArgs: ["node"],
69 | *
70 | * // supply additional arguments to the packager
71 | * extraPackagerArgs: []
72 | * ]
73 | */
74 |
75 | project.ext.react = [
76 | entryFile: "index.js"
77 | ]
78 |
79 | apply from: "../../node_modules/react-native/react.gradle"
80 |
81 | /**
82 | * Set this to true to create two separate APKs instead of one:
83 | * - An APK that only works on ARM devices
84 | * - An APK that only works on x86 devices
85 | * The advantage is the size of the APK is reduced by about 4MB.
86 | * Upload all the APKs to the Play Store and people will download
87 | * the correct one based on the CPU architecture of their device.
88 | */
89 | def enableSeparateBuildPerCPUArchitecture = false
90 |
91 | /**
92 | * Run Proguard to shrink the Java bytecode in release builds.
93 | */
94 | def enableProguardInReleaseBuilds = false
95 |
96 | android {
97 | compileSdkVersion rootProject.ext.compileSdkVersion
98 | buildToolsVersion rootProject.ext.buildToolsVersion
99 |
100 | defaultConfig {
101 | applicationId "com.example"
102 | minSdkVersion rootProject.ext.minSdkVersion
103 | targetSdkVersion rootProject.ext.targetSdkVersion
104 | versionCode 1
105 | versionName "1.0"
106 | ndk {
107 | abiFilters "armeabi-v7a", "x86"
108 | }
109 | }
110 | splits {
111 | abi {
112 | reset()
113 | enable enableSeparateBuildPerCPUArchitecture
114 | universalApk false // If true, also generate a universal APK
115 | include "armeabi-v7a", "x86"
116 | }
117 | }
118 | buildTypes {
119 | release {
120 | minifyEnabled enableProguardInReleaseBuilds
121 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro"
122 | }
123 | }
124 | // applicationVariants are e.g. debug, release
125 | applicationVariants.all { variant ->
126 | variant.outputs.each { output ->
127 | // For each separate APK per architecture, set a unique version code as described here:
128 | // http://tools.android.com/tech-docs/new-build-system/user-guide/apk-splits
129 | def versionCodes = ["armeabi-v7a":1, "x86":2]
130 | def abi = output.getFilter(OutputFile.ABI)
131 | if (abi != null) { // null for the universal-debug, universal-release variants
132 | output.versionCodeOverride =
133 | versionCodes.get(abi) * 1048576 + defaultConfig.versionCode
134 | }
135 | }
136 | }
137 | }
138 |
139 | dependencies {
140 | compile project(':react-native-directed-scrollview')
141 | implementation fileTree(dir: "libs", include: ["*.jar"])
142 | implementation "com.android.support:appcompat-v7:${rootProject.ext.supportLibVersion}"
143 | implementation "com.facebook.react:react-native:+" // From node_modules
144 | }
145 |
146 | // Run this once to be able to run the application with BUCK
147 | // puts all compile dependencies into folder libs for BUCK to use
148 | task copyDownloadableDepsToLibs(type: Copy) {
149 | from configurations.compile
150 | into 'libs'
151 | }
152 |
--------------------------------------------------------------------------------
/example/android/app/proguard-rules.pro:
--------------------------------------------------------------------------------
1 | # Add project specific ProGuard rules here.
2 | # By default, the flags in this file are appended to flags specified
3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt
4 | # You can edit the include path and order by changing the proguardFiles
5 | # directive in build.gradle.
6 | #
7 | # For more details, see
8 | # http://developer.android.com/guide/developing/tools/proguard.html
9 |
10 | # Add any project specific keep options here:
11 |
12 | # If your project uses WebView with JS, uncomment the following
13 | # and specify the fully qualified class name to the JavaScript interface
14 | # class:
15 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview {
16 | # public *;
17 | #}
18 |
--------------------------------------------------------------------------------
/example/android/app/src/main/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
3 |
4 |
5 |
6 |
7 |
13 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
--------------------------------------------------------------------------------
/example/android/app/src/main/java/com/example/MainActivity.java:
--------------------------------------------------------------------------------
1 | package com.example;
2 |
3 | import com.facebook.react.ReactActivity;
4 |
5 | public class MainActivity extends ReactActivity {
6 |
7 | /**
8 | * Returns the name of the main component registered from JavaScript.
9 | * This is used to schedule rendering of the component.
10 | */
11 | @Override
12 | protected String getMainComponentName() {
13 | return "example";
14 | }
15 | }
16 |
--------------------------------------------------------------------------------
/example/android/app/src/main/java/com/example/MainApplication.java:
--------------------------------------------------------------------------------
1 | package com.example;
2 |
3 | import android.app.Application;
4 |
5 | import com.facebook.react.ReactApplication;
6 | import com.rnds.DirectedScrollViewPackage;
7 | import com.facebook.react.ReactNativeHost;
8 | import com.facebook.react.ReactPackage;
9 | import com.facebook.react.shell.MainReactPackage;
10 | import com.facebook.soloader.SoLoader;
11 |
12 | import java.util.Arrays;
13 | import java.util.List;
14 |
15 | public class MainApplication extends Application implements ReactApplication {
16 |
17 | private final ReactNativeHost mReactNativeHost = new ReactNativeHost(this) {
18 | @Override
19 | public boolean getUseDeveloperSupport() {
20 | return BuildConfig.DEBUG;
21 | }
22 |
23 | @Override
24 | protected List getPackages() {
25 | return Arrays.asList(
26 | new MainReactPackage(),
27 | new DirectedScrollViewPackage()
28 | );
29 | }
30 |
31 | @Override
32 | protected String getJSMainModuleName() {
33 | return "index";
34 | }
35 | };
36 |
37 | @Override
38 | public ReactNativeHost getReactNativeHost() {
39 | return mReactNativeHost;
40 | }
41 |
42 | @Override
43 | public void onCreate() {
44 | super.onCreate();
45 | SoLoader.init(this, /* native exopackage */ false);
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
--------------------------------------------------------------------------------
/example/android/app/src/main/res/values/strings.xml:
--------------------------------------------------------------------------------
1 |
2 | example
3 |
4 |
--------------------------------------------------------------------------------
/example/android/app/src/main/res/values/styles.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/example/android/build.gradle:
--------------------------------------------------------------------------------
1 | // Top-level build file where you can add configuration options common to all sub-projects/modules.
2 |
3 | buildscript {
4 | ext {
5 | buildToolsVersion = "27.0.3"
6 | minSdkVersion = 16
7 | compileSdkVersion = 27
8 | targetSdkVersion = 26
9 | supportLibVersion = "27.1.1"
10 | }
11 | repositories {
12 | google()
13 | jcenter()
14 | }
15 | dependencies {
16 | classpath 'com.android.tools.build:gradle:3.1.4'
17 |
18 | // NOTE: Do not place your application dependencies here; they belong
19 | // in the individual module build.gradle files
20 | }
21 | }
22 |
23 | allprojects {
24 | repositories {
25 | mavenLocal()
26 | google()
27 | jcenter()
28 | maven {
29 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
30 | url "$rootDir/../node_modules/react-native/android"
31 | }
32 | }
33 | }
34 |
35 |
36 | task wrapper(type: Wrapper) {
37 | gradleVersion = '4.4'
38 | distributionUrl = distributionUrl.replace("bin", "all")
39 | }
40 |
--------------------------------------------------------------------------------
/example/android/gradle.properties:
--------------------------------------------------------------------------------
1 | # Project-wide Gradle settings.
2 |
3 | # IDE (e.g. Android Studio) users:
4 | # Gradle settings configured through the IDE *will override*
5 | # any settings specified in this file.
6 |
7 | # For more details on how to configure your build environment visit
8 | # http://www.gradle.org/docs/current/userguide/build_environment.html
9 |
10 | # Specifies the JVM arguments used for the daemon process.
11 | # The setting is particularly useful for tweaking memory settings.
12 | # Default value: -Xmx10248m -XX:MaxPermSize=256m
13 | # org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
14 |
15 | # When configured, Gradle will run in incubating parallel mode.
16 | # This option should only be used with decoupled projects. More details, visit
17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
18 | # org.gradle.parallel=true
19 |
--------------------------------------------------------------------------------
/example/android/gradle/wrapper/gradle-wrapper.jar:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/android/gradle/wrapper/gradle-wrapper.jar
--------------------------------------------------------------------------------
/example/android/gradle/wrapper/gradle-wrapper.properties:
--------------------------------------------------------------------------------
1 | distributionBase=GRADLE_USER_HOME
2 | distributionPath=wrapper/dists
3 | zipStoreBase=GRADLE_USER_HOME
4 | zipStorePath=wrapper/dists
5 | distributionUrl=https\://services.gradle.org/distributions/gradle-4.4-all.zip
6 |
--------------------------------------------------------------------------------
/example/android/gradlew:
--------------------------------------------------------------------------------
1 | #!/usr/bin/env sh
2 |
3 | ##############################################################################
4 | ##
5 | ## Gradle start up script for UN*X
6 | ##
7 | ##############################################################################
8 |
9 | # Attempt to set APP_HOME
10 | # Resolve links: $0 may be a link
11 | PRG="$0"
12 | # Need this for relative symlinks.
13 | while [ -h "$PRG" ] ; do
14 | ls=`ls -ld "$PRG"`
15 | link=`expr "$ls" : '.*-> \(.*\)$'`
16 | if expr "$link" : '/.*' > /dev/null; then
17 | PRG="$link"
18 | else
19 | PRG=`dirname "$PRG"`"/$link"
20 | fi
21 | done
22 | SAVED="`pwd`"
23 | cd "`dirname \"$PRG\"`/" >/dev/null
24 | APP_HOME="`pwd -P`"
25 | cd "$SAVED" >/dev/null
26 |
27 | APP_NAME="Gradle"
28 | APP_BASE_NAME=`basename "$0"`
29 |
30 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
31 | DEFAULT_JVM_OPTS=""
32 |
33 | # Use the maximum available, or set MAX_FD != -1 to use that value.
34 | MAX_FD="maximum"
35 |
36 | warn () {
37 | echo "$*"
38 | }
39 |
40 | die () {
41 | echo
42 | echo "$*"
43 | echo
44 | exit 1
45 | }
46 |
47 | # OS specific support (must be 'true' or 'false').
48 | cygwin=false
49 | msys=false
50 | darwin=false
51 | nonstop=false
52 | case "`uname`" in
53 | CYGWIN* )
54 | cygwin=true
55 | ;;
56 | Darwin* )
57 | darwin=true
58 | ;;
59 | MINGW* )
60 | msys=true
61 | ;;
62 | NONSTOP* )
63 | nonstop=true
64 | ;;
65 | esac
66 |
67 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
68 |
69 | # Determine the Java command to use to start the JVM.
70 | if [ -n "$JAVA_HOME" ] ; then
71 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
72 | # IBM's JDK on AIX uses strange locations for the executables
73 | JAVACMD="$JAVA_HOME/jre/sh/java"
74 | else
75 | JAVACMD="$JAVA_HOME/bin/java"
76 | fi
77 | if [ ! -x "$JAVACMD" ] ; then
78 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
79 |
80 | Please set the JAVA_HOME variable in your environment to match the
81 | location of your Java installation."
82 | fi
83 | else
84 | JAVACMD="java"
85 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
86 |
87 | Please set the JAVA_HOME variable in your environment to match the
88 | location of your Java installation."
89 | fi
90 |
91 | # Increase the maximum file descriptors if we can.
92 | if [ "$cygwin" = "false" -a "$darwin" = "false" -a "$nonstop" = "false" ] ; then
93 | MAX_FD_LIMIT=`ulimit -H -n`
94 | if [ $? -eq 0 ] ; then
95 | if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
96 | MAX_FD="$MAX_FD_LIMIT"
97 | fi
98 | ulimit -n $MAX_FD
99 | if [ $? -ne 0 ] ; then
100 | warn "Could not set maximum file descriptor limit: $MAX_FD"
101 | fi
102 | else
103 | warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
104 | fi
105 | fi
106 |
107 | # For Darwin, add options to specify how the application appears in the dock
108 | if $darwin; then
109 | GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
110 | fi
111 |
112 | # For Cygwin, switch paths to Windows format before running java
113 | if $cygwin ; then
114 | APP_HOME=`cygpath --path --mixed "$APP_HOME"`
115 | CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
116 | JAVACMD=`cygpath --unix "$JAVACMD"`
117 |
118 | # We build the pattern for arguments to be converted via cygpath
119 | ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
120 | SEP=""
121 | for dir in $ROOTDIRSRAW ; do
122 | ROOTDIRS="$ROOTDIRS$SEP$dir"
123 | SEP="|"
124 | done
125 | OURCYGPATTERN="(^($ROOTDIRS))"
126 | # Add a user-defined pattern to the cygpath arguments
127 | if [ "$GRADLE_CYGPATTERN" != "" ] ; then
128 | OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
129 | fi
130 | # Now convert the arguments - kludge to limit ourselves to /bin/sh
131 | i=0
132 | for arg in "$@" ; do
133 | CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
134 | CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
135 |
136 | if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
137 | eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
138 | else
139 | eval `echo args$i`="\"$arg\""
140 | fi
141 | i=$((i+1))
142 | done
143 | case $i in
144 | (0) set -- ;;
145 | (1) set -- "$args0" ;;
146 | (2) set -- "$args0" "$args1" ;;
147 | (3) set -- "$args0" "$args1" "$args2" ;;
148 | (4) set -- "$args0" "$args1" "$args2" "$args3" ;;
149 | (5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
150 | (6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
151 | (7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
152 | (8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
153 | (9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
154 | esac
155 | fi
156 |
157 | # Escape application args
158 | save () {
159 | for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
160 | echo " "
161 | }
162 | APP_ARGS=$(save "$@")
163 |
164 | # Collect all arguments for the java command, following the shell quoting and substitution rules
165 | eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
166 |
167 | # by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
168 | if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
169 | cd "$(dirname "$0")"
170 | fi
171 |
172 | exec "$JAVACMD" "$@"
173 |
--------------------------------------------------------------------------------
/example/android/gradlew.bat:
--------------------------------------------------------------------------------
1 | @if "%DEBUG%" == "" @echo off
2 | @rem ##########################################################################
3 | @rem
4 | @rem Gradle startup script for Windows
5 | @rem
6 | @rem ##########################################################################
7 |
8 | @rem Set local scope for the variables with windows NT shell
9 | if "%OS%"=="Windows_NT" setlocal
10 |
11 | set DIRNAME=%~dp0
12 | if "%DIRNAME%" == "" set DIRNAME=.
13 | set APP_BASE_NAME=%~n0
14 | set APP_HOME=%DIRNAME%
15 |
16 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
17 | set DEFAULT_JVM_OPTS=
18 |
19 | @rem Find java.exe
20 | if defined JAVA_HOME goto findJavaFromJavaHome
21 |
22 | set JAVA_EXE=java.exe
23 | %JAVA_EXE% -version >NUL 2>&1
24 | if "%ERRORLEVEL%" == "0" goto init
25 |
26 | echo.
27 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
28 | echo.
29 | echo Please set the JAVA_HOME variable in your environment to match the
30 | echo location of your Java installation.
31 |
32 | goto fail
33 |
34 | :findJavaFromJavaHome
35 | set JAVA_HOME=%JAVA_HOME:"=%
36 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe
37 |
38 | if exist "%JAVA_EXE%" goto init
39 |
40 | echo.
41 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
42 | echo.
43 | echo Please set the JAVA_HOME variable in your environment to match the
44 | echo location of your Java installation.
45 |
46 | goto fail
47 |
48 | :init
49 | @rem Get command-line arguments, handling Windows variants
50 |
51 | if not "%OS%" == "Windows_NT" goto win9xME_args
52 |
53 | :win9xME_args
54 | @rem Slurp the command line arguments.
55 | set CMD_LINE_ARGS=
56 | set _SKIP=2
57 |
58 | :win9xME_args_slurp
59 | if "x%~1" == "x" goto execute
60 |
61 | set CMD_LINE_ARGS=%*
62 |
63 | :execute
64 | @rem Setup the command line
65 |
66 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
67 |
68 | @rem Execute Gradle
69 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
70 |
71 | :end
72 | @rem End local scope for the variables with windows NT shell
73 | if "%ERRORLEVEL%"=="0" goto mainEnd
74 |
75 | :fail
76 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
77 | rem the _cmd.exe /c_ return code!
78 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
79 | exit /b 1
80 |
81 | :mainEnd
82 | if "%OS%"=="Windows_NT" endlocal
83 |
84 | :omega
85 |
--------------------------------------------------------------------------------
/example/android/keystores/BUCK:
--------------------------------------------------------------------------------
1 | keystore(
2 | name = "debug",
3 | properties = "debug.keystore.properties",
4 | store = "debug.keystore",
5 | visibility = [
6 | "PUBLIC",
7 | ],
8 | )
9 |
--------------------------------------------------------------------------------
/example/android/keystores/debug.keystore.properties:
--------------------------------------------------------------------------------
1 | key.store=debug.keystore
2 | key.alias=androiddebugkey
3 | key.store.password=android
4 | key.alias.password=android
5 |
--------------------------------------------------------------------------------
/example/android/settings.gradle:
--------------------------------------------------------------------------------
1 | rootProject.name = 'example'
2 | include ':react-native-directed-scrollview'
3 | project(':react-native-directed-scrollview').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-directed-scrollview/android')
4 |
5 | include ':app'
6 |
--------------------------------------------------------------------------------
/example/app.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "example",
3 | "displayName": "example"
4 | }
--------------------------------------------------------------------------------
/example/index.js:
--------------------------------------------------------------------------------
1 | import React, { Component } from "react";
2 | import { AppRegistry, StyleSheet, SafeAreaView } from "react-native";
3 |
4 | import Grid from "./src/components/Grid";
5 | import { name as appName } from "./app.json";
6 |
7 | class App extends Component {
8 | render() {
9 | return (
10 |
11 |
12 |
13 | );
14 | }
15 | }
16 |
17 | const styles = StyleSheet.create({
18 | container: {
19 | flex: 1
20 | }
21 | });
22 |
23 | AppRegistry.registerComponent(appName, () => App);
24 |
--------------------------------------------------------------------------------
/example/ios/example-tvOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 | LSRequiresIPhoneOS
24 |
25 | UILaunchStoryboardName
26 | LaunchScreen
27 | UIRequiredDeviceCapabilities
28 |
29 | armv7
30 |
31 | UISupportedInterfaceOrientations
32 |
33 | UIInterfaceOrientationPortrait
34 | UIInterfaceOrientationLandscapeLeft
35 | UIInterfaceOrientationLandscapeRight
36 |
37 | UIViewControllerBasedStatusBarAppearance
38 |
39 | NSLocationWhenInUseUsageDescription
40 |
41 | NSAppTransportSecurity
42 |
43 |
44 | NSExceptionDomains
45 |
46 | localhost
47 |
48 | NSExceptionAllowsInsecureHTTPLoads
49 |
50 |
51 |
52 |
53 |
54 |
55 |
--------------------------------------------------------------------------------
/example/ios/example-tvOSTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/example/ios/example.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 | /* Begin PBXBuildFile section */
9 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */; };
10 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */; };
11 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */; };
12 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */; };
13 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */; };
14 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* exampleTests.m */; };
15 | 11D1A2F320CAFA9E000508D9 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */; };
16 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 78C398B91ACF4ADC00677621 /* libRCTLinking.a */; };
17 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */; };
18 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */; };
19 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; };
20 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB11A68108700A75B9A /* LaunchScreen.xib */; };
21 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
22 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
23 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
24 | 146834051AC3E58100842450 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 146834041AC3E56700842450 /* libReact.a */; };
25 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.m */; };
26 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; };
27 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; };
28 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */; };
29 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */; };
30 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */; };
31 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */; };
32 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */; };
33 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */; };
34 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */; };
35 | 2D16E6881FA4F8E400B85C8A /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2D16E6891FA4F8E400B85C8A /* libReact.a */; };
36 | 2DCD954D1E0B4F2C00145EB5 /* exampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* exampleTests.m */; };
37 | 2DF0FFEE2056DD460020B375 /* libReact.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3DAD3EA31DF850E9000B6D8A /* libReact.a */; };
38 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 832341B51AAA6A8300B99B32 /* libRCTText.a */; };
39 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */ = {isa = PBXBuildFile; fileRef = ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */; };
40 | 1039FEA1564C41488A466887 /* libRCTDirectedScrollView.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 2DD24CF3B2354369BFD28315 /* libRCTDirectedScrollView.a */; };
41 | /* End PBXBuildFile section */
42 |
43 | /* Begin PBXContainerItemProxy section */
44 | 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */ = {
45 | isa = PBXContainerItemProxy;
46 | containerPortal = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */;
47 | proxyType = 2;
48 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
49 | remoteInfo = RCTActionSheet;
50 | };
51 | 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */ = {
52 | isa = PBXContainerItemProxy;
53 | containerPortal = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */;
54 | proxyType = 2;
55 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
56 | remoteInfo = RCTGeolocation;
57 | };
58 | 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */ = {
59 | isa = PBXContainerItemProxy;
60 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
61 | proxyType = 2;
62 | remoteGlobalIDString = 58B5115D1A9E6B3D00147676;
63 | remoteInfo = RCTImage;
64 | };
65 | 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */ = {
66 | isa = PBXContainerItemProxy;
67 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
68 | proxyType = 2;
69 | remoteGlobalIDString = 58B511DB1A9E6C8500147676;
70 | remoteInfo = RCTNetwork;
71 | };
72 | 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */ = {
73 | isa = PBXContainerItemProxy;
74 | containerPortal = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */;
75 | proxyType = 2;
76 | remoteGlobalIDString = 832C81801AAF6DEF007FA2F7;
77 | remoteInfo = RCTVibration;
78 | };
79 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = {
80 | isa = PBXContainerItemProxy;
81 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */;
82 | proxyType = 1;
83 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A;
84 | remoteInfo = example;
85 | };
86 | 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */ = {
87 | isa = PBXContainerItemProxy;
88 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
89 | proxyType = 2;
90 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
91 | remoteInfo = RCTSettings;
92 | };
93 | 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */ = {
94 | isa = PBXContainerItemProxy;
95 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
96 | proxyType = 2;
97 | remoteGlobalIDString = 3C86DF461ADF2C930047B81A;
98 | remoteInfo = RCTWebSocket;
99 | };
100 | 146834031AC3E56700842450 /* PBXContainerItemProxy */ = {
101 | isa = PBXContainerItemProxy;
102 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
103 | proxyType = 2;
104 | remoteGlobalIDString = 83CBBA2E1A601D0E00E9B192;
105 | remoteInfo = React;
106 | };
107 | 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */ = {
108 | isa = PBXContainerItemProxy;
109 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */;
110 | proxyType = 1;
111 | remoteGlobalIDString = 2D02E47A1E0B4A5D006451C7;
112 | remoteInfo = "example-tvOS";
113 | };
114 | 2D16E6711FA4F8DC00B85C8A /* PBXContainerItemProxy */ = {
115 | isa = PBXContainerItemProxy;
116 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */;
117 | proxyType = 2;
118 | remoteGlobalIDString = ADD01A681E09402E00F6D226;
119 | remoteInfo = "RCTBlob-tvOS";
120 | };
121 | 2D16E6831FA4F8DC00B85C8A /* PBXContainerItemProxy */ = {
122 | isa = PBXContainerItemProxy;
123 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
124 | proxyType = 2;
125 | remoteGlobalIDString = 3DBE0D001F3B181A0099AA32;
126 | remoteInfo = fishhook;
127 | };
128 | 2D16E6851FA4F8DC00B85C8A /* PBXContainerItemProxy */ = {
129 | isa = PBXContainerItemProxy;
130 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
131 | proxyType = 2;
132 | remoteGlobalIDString = 3DBE0D0D1F3B181C0099AA32;
133 | remoteInfo = "fishhook-tvOS";
134 | };
135 | 2DF0FFDE2056DD460020B375 /* PBXContainerItemProxy */ = {
136 | isa = PBXContainerItemProxy;
137 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
138 | proxyType = 2;
139 | remoteGlobalIDString = EBF21BDC1FC498900052F4D5;
140 | remoteInfo = jsinspector;
141 | };
142 | 2DF0FFE02056DD460020B375 /* PBXContainerItemProxy */ = {
143 | isa = PBXContainerItemProxy;
144 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
145 | proxyType = 2;
146 | remoteGlobalIDString = EBF21BFA1FC4989A0052F4D5;
147 | remoteInfo = "jsinspector-tvOS";
148 | };
149 | 2DF0FFE22056DD460020B375 /* PBXContainerItemProxy */ = {
150 | isa = PBXContainerItemProxy;
151 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
152 | proxyType = 2;
153 | remoteGlobalIDString = 139D7ECE1E25DB7D00323FB7;
154 | remoteInfo = "third-party";
155 | };
156 | 2DF0FFE42056DD460020B375 /* PBXContainerItemProxy */ = {
157 | isa = PBXContainerItemProxy;
158 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
159 | proxyType = 2;
160 | remoteGlobalIDString = 3D383D3C1EBD27B6005632C8;
161 | remoteInfo = "third-party-tvOS";
162 | };
163 | 2DF0FFE62056DD460020B375 /* PBXContainerItemProxy */ = {
164 | isa = PBXContainerItemProxy;
165 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
166 | proxyType = 2;
167 | remoteGlobalIDString = 139D7E881E25C6D100323FB7;
168 | remoteInfo = "double-conversion";
169 | };
170 | 2DF0FFE82056DD460020B375 /* PBXContainerItemProxy */ = {
171 | isa = PBXContainerItemProxy;
172 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
173 | proxyType = 2;
174 | remoteGlobalIDString = 3D383D621EBD27B9005632C8;
175 | remoteInfo = "double-conversion-tvOS";
176 | };
177 | 2DF0FFEA2056DD460020B375 /* PBXContainerItemProxy */ = {
178 | isa = PBXContainerItemProxy;
179 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
180 | proxyType = 2;
181 | remoteGlobalIDString = 9936F3131F5F2E4B0010BF04;
182 | remoteInfo = privatedata;
183 | };
184 | 2DF0FFEC2056DD460020B375 /* PBXContainerItemProxy */ = {
185 | isa = PBXContainerItemProxy;
186 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
187 | proxyType = 2;
188 | remoteGlobalIDString = 9936F32F1F5F2E5B0010BF04;
189 | remoteInfo = "privatedata-tvOS";
190 | };
191 | 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */ = {
192 | isa = PBXContainerItemProxy;
193 | containerPortal = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
194 | proxyType = 2;
195 | remoteGlobalIDString = 2D2A283A1D9B042B00D4039D;
196 | remoteInfo = "RCTImage-tvOS";
197 | };
198 | 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */ = {
199 | isa = PBXContainerItemProxy;
200 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
201 | proxyType = 2;
202 | remoteGlobalIDString = 2D2A28471D9B043800D4039D;
203 | remoteInfo = "RCTLinking-tvOS";
204 | };
205 | 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
206 | isa = PBXContainerItemProxy;
207 | containerPortal = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
208 | proxyType = 2;
209 | remoteGlobalIDString = 2D2A28541D9B044C00D4039D;
210 | remoteInfo = "RCTNetwork-tvOS";
211 | };
212 | 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
213 | isa = PBXContainerItemProxy;
214 | containerPortal = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
215 | proxyType = 2;
216 | remoteGlobalIDString = 2D2A28611D9B046600D4039D;
217 | remoteInfo = "RCTSettings-tvOS";
218 | };
219 | 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */ = {
220 | isa = PBXContainerItemProxy;
221 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
222 | proxyType = 2;
223 | remoteGlobalIDString = 2D2A287B1D9B048500D4039D;
224 | remoteInfo = "RCTText-tvOS";
225 | };
226 | 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */ = {
227 | isa = PBXContainerItemProxy;
228 | containerPortal = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
229 | proxyType = 2;
230 | remoteGlobalIDString = 2D2A28881D9B049200D4039D;
231 | remoteInfo = "RCTWebSocket-tvOS";
232 | };
233 | 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */ = {
234 | isa = PBXContainerItemProxy;
235 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
236 | proxyType = 2;
237 | remoteGlobalIDString = 2D2A28131D9B038B00D4039D;
238 | remoteInfo = "React-tvOS";
239 | };
240 | 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */ = {
241 | isa = PBXContainerItemProxy;
242 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
243 | proxyType = 2;
244 | remoteGlobalIDString = 3D3C059A1DE3340900C268FA;
245 | remoteInfo = yoga;
246 | };
247 | 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */ = {
248 | isa = PBXContainerItemProxy;
249 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
250 | proxyType = 2;
251 | remoteGlobalIDString = 3D3C06751DE3340C00C268FA;
252 | remoteInfo = "yoga-tvOS";
253 | };
254 | 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */ = {
255 | isa = PBXContainerItemProxy;
256 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
257 | proxyType = 2;
258 | remoteGlobalIDString = 3D3CD9251DE5FBEC00167DC4;
259 | remoteInfo = cxxreact;
260 | };
261 | 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
262 | isa = PBXContainerItemProxy;
263 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
264 | proxyType = 2;
265 | remoteGlobalIDString = 3D3CD9321DE5FBEE00167DC4;
266 | remoteInfo = "cxxreact-tvOS";
267 | };
268 | 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
269 | isa = PBXContainerItemProxy;
270 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
271 | proxyType = 2;
272 | remoteGlobalIDString = 3D3CD90B1DE5FBD600167DC4;
273 | remoteInfo = jschelpers;
274 | };
275 | 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */ = {
276 | isa = PBXContainerItemProxy;
277 | containerPortal = 146833FF1AC3E56700842450 /* React.xcodeproj */;
278 | proxyType = 2;
279 | remoteGlobalIDString = 3D3CD9181DE5FBD800167DC4;
280 | remoteInfo = "jschelpers-tvOS";
281 | };
282 | 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = {
283 | isa = PBXContainerItemProxy;
284 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
285 | proxyType = 2;
286 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
287 | remoteInfo = RCTAnimation;
288 | };
289 | 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */ = {
290 | isa = PBXContainerItemProxy;
291 | containerPortal = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
292 | proxyType = 2;
293 | remoteGlobalIDString = 2D2A28201D9B03D100D4039D;
294 | remoteInfo = "RCTAnimation-tvOS";
295 | };
296 | 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */ = {
297 | isa = PBXContainerItemProxy;
298 | containerPortal = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
299 | proxyType = 2;
300 | remoteGlobalIDString = 134814201AA4EA6300B7C361;
301 | remoteInfo = RCTLinking;
302 | };
303 | 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */ = {
304 | isa = PBXContainerItemProxy;
305 | containerPortal = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
306 | proxyType = 2;
307 | remoteGlobalIDString = 58B5119B1A9E6C1200147676;
308 | remoteInfo = RCTText;
309 | };
310 | ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */ = {
311 | isa = PBXContainerItemProxy;
312 | containerPortal = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */;
313 | proxyType = 2;
314 | remoteGlobalIDString = 358F4ED71D1E81A9004DF814;
315 | remoteInfo = RCTBlob;
316 | };
317 | /* End PBXContainerItemProxy section */
318 |
319 | /* Begin PBXFileReference section */
320 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = main.jsbundle; sourceTree = ""; };
321 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTActionSheet.xcodeproj; path = "../node_modules/react-native/Libraries/ActionSheetIOS/RCTActionSheet.xcodeproj"; sourceTree = ""; };
322 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTGeolocation.xcodeproj; path = "../node_modules/react-native/Libraries/Geolocation/RCTGeolocation.xcodeproj"; sourceTree = ""; };
323 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTImage.xcodeproj; path = "../node_modules/react-native/Libraries/Image/RCTImage.xcodeproj"; sourceTree = ""; };
324 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTNetwork.xcodeproj; path = "../node_modules/react-native/Libraries/Network/RCTNetwork.xcodeproj"; sourceTree = ""; };
325 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTVibration.xcodeproj; path = "../node_modules/react-native/Libraries/Vibration/RCTVibration.xcodeproj"; sourceTree = ""; };
326 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = exampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
327 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
328 | 00E356F21AD99517003FC87E /* exampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = exampleTests.m; sourceTree = ""; };
329 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTSettings.xcodeproj; path = "../node_modules/react-native/Libraries/Settings/RCTSettings.xcodeproj"; sourceTree = ""; };
330 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTWebSocket.xcodeproj; path = "../node_modules/react-native/Libraries/WebSocket/RCTWebSocket.xcodeproj"; sourceTree = ""; };
331 | 13B07F961A680F5B00A75B9A /* example.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = example.app; sourceTree = BUILT_PRODUCTS_DIR; };
332 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = example/AppDelegate.h; sourceTree = ""; };
333 | 13B07FB01A68108700A75B9A /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = example/AppDelegate.m; sourceTree = ""; };
334 | 13B07FB21A68108700A75B9A /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/LaunchScreen.xib; sourceTree = ""; };
335 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = example/Images.xcassets; sourceTree = ""; };
336 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = example/Info.plist; sourceTree = ""; };
337 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = example/main.m; sourceTree = ""; };
338 | 146833FF1AC3E56700842450 /* React.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = React.xcodeproj; path = "../node_modules/react-native/React/React.xcodeproj"; sourceTree = ""; };
339 | 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "example-tvOS.app"; sourceTree = BUILT_PRODUCTS_DIR; };
340 | 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "example-tvOSTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; };
341 | 2D16E6891FA4F8E400B85C8A /* libReact.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; path = libReact.a; sourceTree = BUILT_PRODUCTS_DIR; };
342 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTAnimation.xcodeproj; path = "../node_modules/react-native/Libraries/NativeAnimation/RCTAnimation.xcodeproj"; sourceTree = ""; };
343 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTLinking.xcodeproj; path = "../node_modules/react-native/Libraries/LinkingIOS/RCTLinking.xcodeproj"; sourceTree = ""; };
344 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTText.xcodeproj; path = "../node_modules/react-native/Libraries/Text/RCTText.xcodeproj"; sourceTree = ""; };
345 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */ = {isa = PBXFileReference; lastKnownFileType = "wrapper.pb-project"; name = RCTBlob.xcodeproj; path = "../node_modules/react-native/Libraries/Blob/RCTBlob.xcodeproj"; sourceTree = ""; };
346 | 2ED062EB14E84362931D6281 /* RCTDirectedScrollView.xcodeproj */ = {isa = PBXFileReference; name = "RCTDirectedScrollView.xcodeproj"; path = "../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView.xcodeproj"; sourceTree = ""; fileEncoding = undefined; lastKnownFileType = wrapper.pb-project; explicitFileType = undefined; includeInIndex = 0; };
347 | 2DD24CF3B2354369BFD28315 /* libRCTDirectedScrollView.a */ = {isa = PBXFileReference; name = "libRCTDirectedScrollView.a"; path = "libRCTDirectedScrollView.a"; sourceTree = ""; fileEncoding = undefined; lastKnownFileType = archive.ar; explicitFileType = undefined; includeInIndex = 0; };
348 | /* End PBXFileReference section */
349 |
350 | /* Begin PBXFrameworksBuildPhase section */
351 | 00E356EB1AD99517003FC87E /* Frameworks */ = {
352 | isa = PBXFrameworksBuildPhase;
353 | buildActionMask = 2147483647;
354 | files = (
355 | 140ED2AC1D01E1AD002B40FF /* libReact.a in Frameworks */,
356 | );
357 | runOnlyForDeploymentPostprocessing = 0;
358 | };
359 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = {
360 | isa = PBXFrameworksBuildPhase;
361 | buildActionMask = 2147483647;
362 | files = (
363 | ADBDB9381DFEBF1600ED6528 /* libRCTBlob.a in Frameworks */,
364 | 11D1A2F320CAFA9E000508D9 /* libRCTAnimation.a in Frameworks */,
365 | 146834051AC3E58100842450 /* libReact.a in Frameworks */,
366 | 00C302E51ABCBA2D00DB3ED1 /* libRCTActionSheet.a in Frameworks */,
367 | 00C302E71ABCBA2D00DB3ED1 /* libRCTGeolocation.a in Frameworks */,
368 | 00C302E81ABCBA2D00DB3ED1 /* libRCTImage.a in Frameworks */,
369 | 133E29F31AD74F7200F7D852 /* libRCTLinking.a in Frameworks */,
370 | 00C302E91ABCBA2D00DB3ED1 /* libRCTNetwork.a in Frameworks */,
371 | 139105C61AF99C1200B5F7CC /* libRCTSettings.a in Frameworks */,
372 | 832341BD1AAA6AB300B99B32 /* libRCTText.a in Frameworks */,
373 | 00C302EA1ABCBA2D00DB3ED1 /* libRCTVibration.a in Frameworks */,
374 | 139FDEF61B0652A700C62182 /* libRCTWebSocket.a in Frameworks */,
375 | 1039FEA1564C41488A466887 /* libRCTDirectedScrollView.a in Frameworks */,
376 | );
377 | runOnlyForDeploymentPostprocessing = 0;
378 | };
379 | 2D02E4781E0B4A5D006451C7 /* Frameworks */ = {
380 | isa = PBXFrameworksBuildPhase;
381 | buildActionMask = 2147483647;
382 | files = (
383 | 2D16E6881FA4F8E400B85C8A /* libReact.a in Frameworks */,
384 | 2D02E4C21E0B4AEC006451C7 /* libRCTAnimation.a in Frameworks */,
385 | 2D02E4C31E0B4AEC006451C7 /* libRCTImage-tvOS.a in Frameworks */,
386 | 2D02E4C41E0B4AEC006451C7 /* libRCTLinking-tvOS.a in Frameworks */,
387 | 2D02E4C51E0B4AEC006451C7 /* libRCTNetwork-tvOS.a in Frameworks */,
388 | 2D02E4C61E0B4AEC006451C7 /* libRCTSettings-tvOS.a in Frameworks */,
389 | 2D02E4C71E0B4AEC006451C7 /* libRCTText-tvOS.a in Frameworks */,
390 | 2D02E4C81E0B4AEC006451C7 /* libRCTWebSocket-tvOS.a in Frameworks */,
391 | );
392 | runOnlyForDeploymentPostprocessing = 0;
393 | };
394 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */ = {
395 | isa = PBXFrameworksBuildPhase;
396 | buildActionMask = 2147483647;
397 | files = (
398 | 2DF0FFEE2056DD460020B375 /* libReact.a in Frameworks */,
399 | );
400 | runOnlyForDeploymentPostprocessing = 0;
401 | };
402 | /* End PBXFrameworksBuildPhase section */
403 |
404 | /* Begin PBXGroup section */
405 | 00C302A81ABCB8CE00DB3ED1 /* Products */ = {
406 | isa = PBXGroup;
407 | children = (
408 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */,
409 | );
410 | name = Products;
411 | sourceTree = "";
412 | };
413 | 00C302B61ABCB90400DB3ED1 /* Products */ = {
414 | isa = PBXGroup;
415 | children = (
416 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */,
417 | );
418 | name = Products;
419 | sourceTree = "";
420 | };
421 | 00C302BC1ABCB91800DB3ED1 /* Products */ = {
422 | isa = PBXGroup;
423 | children = (
424 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */,
425 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */,
426 | );
427 | name = Products;
428 | sourceTree = "";
429 | };
430 | 00C302D41ABCB9D200DB3ED1 /* Products */ = {
431 | isa = PBXGroup;
432 | children = (
433 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */,
434 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */,
435 | );
436 | name = Products;
437 | sourceTree = "";
438 | };
439 | 00C302E01ABCB9EE00DB3ED1 /* Products */ = {
440 | isa = PBXGroup;
441 | children = (
442 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */,
443 | );
444 | name = Products;
445 | sourceTree = "";
446 | };
447 | 00E356EF1AD99517003FC87E /* exampleTests */ = {
448 | isa = PBXGroup;
449 | children = (
450 | 00E356F21AD99517003FC87E /* exampleTests.m */,
451 | 00E356F01AD99517003FC87E /* Supporting Files */,
452 | );
453 | path = exampleTests;
454 | sourceTree = "";
455 | };
456 | 00E356F01AD99517003FC87E /* Supporting Files */ = {
457 | isa = PBXGroup;
458 | children = (
459 | 00E356F11AD99517003FC87E /* Info.plist */,
460 | );
461 | name = "Supporting Files";
462 | sourceTree = "";
463 | };
464 | 139105B71AF99BAD00B5F7CC /* Products */ = {
465 | isa = PBXGroup;
466 | children = (
467 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */,
468 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */,
469 | );
470 | name = Products;
471 | sourceTree = "";
472 | };
473 | 139FDEE71B06529A00C62182 /* Products */ = {
474 | isa = PBXGroup;
475 | children = (
476 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */,
477 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */,
478 | 2D16E6841FA4F8DC00B85C8A /* libfishhook.a */,
479 | 2D16E6861FA4F8DC00B85C8A /* libfishhook-tvOS.a */,
480 | );
481 | name = Products;
482 | sourceTree = "";
483 | };
484 | 13B07FAE1A68108700A75B9A /* example */ = {
485 | isa = PBXGroup;
486 | children = (
487 | 008F07F21AC5B25A0029DE68 /* main.jsbundle */,
488 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */,
489 | 13B07FB01A68108700A75B9A /* AppDelegate.m */,
490 | 13B07FB51A68108700A75B9A /* Images.xcassets */,
491 | 13B07FB61A68108700A75B9A /* Info.plist */,
492 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */,
493 | 13B07FB71A68108700A75B9A /* main.m */,
494 | );
495 | name = example;
496 | sourceTree = "";
497 | };
498 | 146834001AC3E56700842450 /* Products */ = {
499 | isa = PBXGroup;
500 | children = (
501 | 146834041AC3E56700842450 /* libReact.a */,
502 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */,
503 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */,
504 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */,
505 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */,
506 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */,
507 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */,
508 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */,
509 | 2DF0FFDF2056DD460020B375 /* libjsinspector.a */,
510 | 2DF0FFE12056DD460020B375 /* libjsinspector-tvOS.a */,
511 | 2DF0FFE32056DD460020B375 /* libthird-party.a */,
512 | 2DF0FFE52056DD460020B375 /* libthird-party.a */,
513 | 2DF0FFE72056DD460020B375 /* libdouble-conversion.a */,
514 | 2DF0FFE92056DD460020B375 /* libdouble-conversion.a */,
515 | 2DF0FFEB2056DD460020B375 /* libprivatedata.a */,
516 | 2DF0FFED2056DD460020B375 /* libprivatedata-tvOS.a */,
517 | );
518 | name = Products;
519 | sourceTree = "";
520 | };
521 | 2D16E6871FA4F8E400B85C8A /* Frameworks */ = {
522 | isa = PBXGroup;
523 | children = (
524 | 2D16E6891FA4F8E400B85C8A /* libReact.a */,
525 | );
526 | name = Frameworks;
527 | sourceTree = "";
528 | };
529 | 5E91572E1DD0AC6500FF2AA8 /* Products */ = {
530 | isa = PBXGroup;
531 | children = (
532 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */,
533 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */,
534 | );
535 | name = Products;
536 | sourceTree = "";
537 | };
538 | 78C398B11ACF4ADC00677621 /* Products */ = {
539 | isa = PBXGroup;
540 | children = (
541 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */,
542 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */,
543 | );
544 | name = Products;
545 | sourceTree = "";
546 | };
547 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = {
548 | isa = PBXGroup;
549 | children = (
550 | 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */,
551 | 146833FF1AC3E56700842450 /* React.xcodeproj */,
552 | 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */,
553 | ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */,
554 | 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */,
555 | 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */,
556 | 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */,
557 | 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */,
558 | 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */,
559 | 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */,
560 | 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */,
561 | 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */,
562 | 2ED062EB14E84362931D6281 /* RCTDirectedScrollView.xcodeproj */,
563 | );
564 | name = Libraries;
565 | sourceTree = "";
566 | };
567 | 832341B11AAA6A8300B99B32 /* Products */ = {
568 | isa = PBXGroup;
569 | children = (
570 | 832341B51AAA6A8300B99B32 /* libRCTText.a */,
571 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */,
572 | );
573 | name = Products;
574 | sourceTree = "";
575 | };
576 | 83CBB9F61A601CBA00E9B192 = {
577 | isa = PBXGroup;
578 | children = (
579 | 13B07FAE1A68108700A75B9A /* example */,
580 | 832341AE1AAA6A7D00B99B32 /* Libraries */,
581 | 00E356EF1AD99517003FC87E /* exampleTests */,
582 | 83CBBA001A601CBA00E9B192 /* Products */,
583 | 2D16E6871FA4F8E400B85C8A /* Frameworks */,
584 | );
585 | indentWidth = 2;
586 | sourceTree = "";
587 | tabWidth = 2;
588 | usesTabs = 0;
589 | };
590 | 83CBBA001A601CBA00E9B192 /* Products */ = {
591 | isa = PBXGroup;
592 | children = (
593 | 13B07F961A680F5B00A75B9A /* example.app */,
594 | 00E356EE1AD99517003FC87E /* exampleTests.xctest */,
595 | 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */,
596 | 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */,
597 | );
598 | name = Products;
599 | sourceTree = "";
600 | };
601 | ADBDB9201DFEBF0600ED6528 /* Products */ = {
602 | isa = PBXGroup;
603 | children = (
604 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */,
605 | 2D16E6721FA4F8DC00B85C8A /* libRCTBlob-tvOS.a */,
606 | );
607 | name = Products;
608 | sourceTree = "";
609 | };
610 | /* End PBXGroup section */
611 |
612 | /* Begin PBXNativeTarget section */
613 | 00E356ED1AD99517003FC87E /* exampleTests */ = {
614 | isa = PBXNativeTarget;
615 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */;
616 | buildPhases = (
617 | 00E356EA1AD99517003FC87E /* Sources */,
618 | 00E356EB1AD99517003FC87E /* Frameworks */,
619 | 00E356EC1AD99517003FC87E /* Resources */,
620 | );
621 | buildRules = (
622 | );
623 | dependencies = (
624 | 00E356F51AD99517003FC87E /* PBXTargetDependency */,
625 | );
626 | name = exampleTests;
627 | productName = exampleTests;
628 | productReference = 00E356EE1AD99517003FC87E /* exampleTests.xctest */;
629 | productType = "com.apple.product-type.bundle.unit-test";
630 | };
631 | 13B07F861A680F5B00A75B9A /* example */ = {
632 | isa = PBXNativeTarget;
633 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */;
634 | buildPhases = (
635 | 13B07F871A680F5B00A75B9A /* Sources */,
636 | 13B07F8C1A680F5B00A75B9A /* Frameworks */,
637 | 13B07F8E1A680F5B00A75B9A /* Resources */,
638 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */,
639 | );
640 | buildRules = (
641 | );
642 | dependencies = (
643 | );
644 | name = example;
645 | productName = "Hello World";
646 | productReference = 13B07F961A680F5B00A75B9A /* example.app */;
647 | productType = "com.apple.product-type.application";
648 | };
649 | 2D02E47A1E0B4A5D006451C7 /* example-tvOS */ = {
650 | isa = PBXNativeTarget;
651 | buildConfigurationList = 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOS" */;
652 | buildPhases = (
653 | 2D02E4771E0B4A5D006451C7 /* Sources */,
654 | 2D02E4781E0B4A5D006451C7 /* Frameworks */,
655 | 2D02E4791E0B4A5D006451C7 /* Resources */,
656 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */,
657 | );
658 | buildRules = (
659 | );
660 | dependencies = (
661 | );
662 | name = "example-tvOS";
663 | productName = "example-tvOS";
664 | productReference = 2D02E47B1E0B4A5D006451C7 /* example-tvOS.app */;
665 | productType = "com.apple.product-type.application";
666 | };
667 | 2D02E48F1E0B4A5D006451C7 /* example-tvOSTests */ = {
668 | isa = PBXNativeTarget;
669 | buildConfigurationList = 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOSTests" */;
670 | buildPhases = (
671 | 2D02E48C1E0B4A5D006451C7 /* Sources */,
672 | 2D02E48D1E0B4A5D006451C7 /* Frameworks */,
673 | 2D02E48E1E0B4A5D006451C7 /* Resources */,
674 | );
675 | buildRules = (
676 | );
677 | dependencies = (
678 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */,
679 | );
680 | name = "example-tvOSTests";
681 | productName = "example-tvOSTests";
682 | productReference = 2D02E4901E0B4A5D006451C7 /* example-tvOSTests.xctest */;
683 | productType = "com.apple.product-type.bundle.unit-test";
684 | };
685 | /* End PBXNativeTarget section */
686 |
687 | /* Begin PBXProject section */
688 | 83CBB9F71A601CBA00E9B192 /* Project object */ = {
689 | isa = PBXProject;
690 | attributes = {
691 | LastUpgradeCheck = 940;
692 | ORGANIZATIONNAME = Facebook;
693 | TargetAttributes = {
694 | 00E356ED1AD99517003FC87E = {
695 | CreatedOnToolsVersion = 6.2;
696 | TestTargetID = 13B07F861A680F5B00A75B9A;
697 | };
698 | 2D02E47A1E0B4A5D006451C7 = {
699 | CreatedOnToolsVersion = 8.2.1;
700 | ProvisioningStyle = Automatic;
701 | };
702 | 2D02E48F1E0B4A5D006451C7 = {
703 | CreatedOnToolsVersion = 8.2.1;
704 | ProvisioningStyle = Automatic;
705 | TestTargetID = 2D02E47A1E0B4A5D006451C7;
706 | };
707 | };
708 | };
709 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */;
710 | compatibilityVersion = "Xcode 3.2";
711 | developmentRegion = English;
712 | hasScannedForEncodings = 0;
713 | knownRegions = (
714 | en,
715 | Base,
716 | );
717 | mainGroup = 83CBB9F61A601CBA00E9B192;
718 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */;
719 | projectDirPath = "";
720 | projectReferences = (
721 | {
722 | ProductGroup = 00C302A81ABCB8CE00DB3ED1 /* Products */;
723 | ProjectRef = 00C302A71ABCB8CE00DB3ED1 /* RCTActionSheet.xcodeproj */;
724 | },
725 | {
726 | ProductGroup = 5E91572E1DD0AC6500FF2AA8 /* Products */;
727 | ProjectRef = 5E91572D1DD0AC6500FF2AA8 /* RCTAnimation.xcodeproj */;
728 | },
729 | {
730 | ProductGroup = ADBDB9201DFEBF0600ED6528 /* Products */;
731 | ProjectRef = ADBDB91F1DFEBF0600ED6528 /* RCTBlob.xcodeproj */;
732 | },
733 | {
734 | ProductGroup = 00C302B61ABCB90400DB3ED1 /* Products */;
735 | ProjectRef = 00C302B51ABCB90400DB3ED1 /* RCTGeolocation.xcodeproj */;
736 | },
737 | {
738 | ProductGroup = 00C302BC1ABCB91800DB3ED1 /* Products */;
739 | ProjectRef = 00C302BB1ABCB91800DB3ED1 /* RCTImage.xcodeproj */;
740 | },
741 | {
742 | ProductGroup = 78C398B11ACF4ADC00677621 /* Products */;
743 | ProjectRef = 78C398B01ACF4ADC00677621 /* RCTLinking.xcodeproj */;
744 | },
745 | {
746 | ProductGroup = 00C302D41ABCB9D200DB3ED1 /* Products */;
747 | ProjectRef = 00C302D31ABCB9D200DB3ED1 /* RCTNetwork.xcodeproj */;
748 | },
749 | {
750 | ProductGroup = 139105B71AF99BAD00B5F7CC /* Products */;
751 | ProjectRef = 139105B61AF99BAD00B5F7CC /* RCTSettings.xcodeproj */;
752 | },
753 | {
754 | ProductGroup = 832341B11AAA6A8300B99B32 /* Products */;
755 | ProjectRef = 832341B01AAA6A8300B99B32 /* RCTText.xcodeproj */;
756 | },
757 | {
758 | ProductGroup = 00C302E01ABCB9EE00DB3ED1 /* Products */;
759 | ProjectRef = 00C302DF1ABCB9EE00DB3ED1 /* RCTVibration.xcodeproj */;
760 | },
761 | {
762 | ProductGroup = 139FDEE71B06529A00C62182 /* Products */;
763 | ProjectRef = 139FDEE61B06529A00C62182 /* RCTWebSocket.xcodeproj */;
764 | },
765 | {
766 | ProductGroup = 146834001AC3E56700842450 /* Products */;
767 | ProjectRef = 146833FF1AC3E56700842450 /* React.xcodeproj */;
768 | },
769 | );
770 | projectRoot = "";
771 | targets = (
772 | 13B07F861A680F5B00A75B9A /* example */,
773 | 00E356ED1AD99517003FC87E /* exampleTests */,
774 | 2D02E47A1E0B4A5D006451C7 /* example-tvOS */,
775 | 2D02E48F1E0B4A5D006451C7 /* example-tvOSTests */,
776 | );
777 | };
778 | /* End PBXProject section */
779 |
780 | /* Begin PBXReferenceProxy section */
781 | 00C302AC1ABCB8CE00DB3ED1 /* libRCTActionSheet.a */ = {
782 | isa = PBXReferenceProxy;
783 | fileType = archive.ar;
784 | path = libRCTActionSheet.a;
785 | remoteRef = 00C302AB1ABCB8CE00DB3ED1 /* PBXContainerItemProxy */;
786 | sourceTree = BUILT_PRODUCTS_DIR;
787 | };
788 | 00C302BA1ABCB90400DB3ED1 /* libRCTGeolocation.a */ = {
789 | isa = PBXReferenceProxy;
790 | fileType = archive.ar;
791 | path = libRCTGeolocation.a;
792 | remoteRef = 00C302B91ABCB90400DB3ED1 /* PBXContainerItemProxy */;
793 | sourceTree = BUILT_PRODUCTS_DIR;
794 | };
795 | 00C302C01ABCB91800DB3ED1 /* libRCTImage.a */ = {
796 | isa = PBXReferenceProxy;
797 | fileType = archive.ar;
798 | path = libRCTImage.a;
799 | remoteRef = 00C302BF1ABCB91800DB3ED1 /* PBXContainerItemProxy */;
800 | sourceTree = BUILT_PRODUCTS_DIR;
801 | };
802 | 00C302DC1ABCB9D200DB3ED1 /* libRCTNetwork.a */ = {
803 | isa = PBXReferenceProxy;
804 | fileType = archive.ar;
805 | path = libRCTNetwork.a;
806 | remoteRef = 00C302DB1ABCB9D200DB3ED1 /* PBXContainerItemProxy */;
807 | sourceTree = BUILT_PRODUCTS_DIR;
808 | };
809 | 00C302E41ABCB9EE00DB3ED1 /* libRCTVibration.a */ = {
810 | isa = PBXReferenceProxy;
811 | fileType = archive.ar;
812 | path = libRCTVibration.a;
813 | remoteRef = 00C302E31ABCB9EE00DB3ED1 /* PBXContainerItemProxy */;
814 | sourceTree = BUILT_PRODUCTS_DIR;
815 | };
816 | 139105C11AF99BAD00B5F7CC /* libRCTSettings.a */ = {
817 | isa = PBXReferenceProxy;
818 | fileType = archive.ar;
819 | path = libRCTSettings.a;
820 | remoteRef = 139105C01AF99BAD00B5F7CC /* PBXContainerItemProxy */;
821 | sourceTree = BUILT_PRODUCTS_DIR;
822 | };
823 | 139FDEF41B06529B00C62182 /* libRCTWebSocket.a */ = {
824 | isa = PBXReferenceProxy;
825 | fileType = archive.ar;
826 | path = libRCTWebSocket.a;
827 | remoteRef = 139FDEF31B06529B00C62182 /* PBXContainerItemProxy */;
828 | sourceTree = BUILT_PRODUCTS_DIR;
829 | };
830 | 146834041AC3E56700842450 /* libReact.a */ = {
831 | isa = PBXReferenceProxy;
832 | fileType = archive.ar;
833 | path = libReact.a;
834 | remoteRef = 146834031AC3E56700842450 /* PBXContainerItemProxy */;
835 | sourceTree = BUILT_PRODUCTS_DIR;
836 | };
837 | 2D16E6721FA4F8DC00B85C8A /* libRCTBlob-tvOS.a */ = {
838 | isa = PBXReferenceProxy;
839 | fileType = archive.ar;
840 | path = "libRCTBlob-tvOS.a";
841 | remoteRef = 2D16E6711FA4F8DC00B85C8A /* PBXContainerItemProxy */;
842 | sourceTree = BUILT_PRODUCTS_DIR;
843 | };
844 | 2D16E6841FA4F8DC00B85C8A /* libfishhook.a */ = {
845 | isa = PBXReferenceProxy;
846 | fileType = archive.ar;
847 | path = libfishhook.a;
848 | remoteRef = 2D16E6831FA4F8DC00B85C8A /* PBXContainerItemProxy */;
849 | sourceTree = BUILT_PRODUCTS_DIR;
850 | };
851 | 2D16E6861FA4F8DC00B85C8A /* libfishhook-tvOS.a */ = {
852 | isa = PBXReferenceProxy;
853 | fileType = archive.ar;
854 | path = "libfishhook-tvOS.a";
855 | remoteRef = 2D16E6851FA4F8DC00B85C8A /* PBXContainerItemProxy */;
856 | sourceTree = BUILT_PRODUCTS_DIR;
857 | };
858 | 2DF0FFDF2056DD460020B375 /* libjsinspector.a */ = {
859 | isa = PBXReferenceProxy;
860 | fileType = archive.ar;
861 | path = libjsinspector.a;
862 | remoteRef = 2DF0FFDE2056DD460020B375 /* PBXContainerItemProxy */;
863 | sourceTree = BUILT_PRODUCTS_DIR;
864 | };
865 | 2DF0FFE12056DD460020B375 /* libjsinspector-tvOS.a */ = {
866 | isa = PBXReferenceProxy;
867 | fileType = archive.ar;
868 | path = "libjsinspector-tvOS.a";
869 | remoteRef = 2DF0FFE02056DD460020B375 /* PBXContainerItemProxy */;
870 | sourceTree = BUILT_PRODUCTS_DIR;
871 | };
872 | 2DF0FFE32056DD460020B375 /* libthird-party.a */ = {
873 | isa = PBXReferenceProxy;
874 | fileType = archive.ar;
875 | path = "libthird-party.a";
876 | remoteRef = 2DF0FFE22056DD460020B375 /* PBXContainerItemProxy */;
877 | sourceTree = BUILT_PRODUCTS_DIR;
878 | };
879 | 2DF0FFE52056DD460020B375 /* libthird-party.a */ = {
880 | isa = PBXReferenceProxy;
881 | fileType = archive.ar;
882 | path = "libthird-party.a";
883 | remoteRef = 2DF0FFE42056DD460020B375 /* PBXContainerItemProxy */;
884 | sourceTree = BUILT_PRODUCTS_DIR;
885 | };
886 | 2DF0FFE72056DD460020B375 /* libdouble-conversion.a */ = {
887 | isa = PBXReferenceProxy;
888 | fileType = archive.ar;
889 | path = "libdouble-conversion.a";
890 | remoteRef = 2DF0FFE62056DD460020B375 /* PBXContainerItemProxy */;
891 | sourceTree = BUILT_PRODUCTS_DIR;
892 | };
893 | 2DF0FFE92056DD460020B375 /* libdouble-conversion.a */ = {
894 | isa = PBXReferenceProxy;
895 | fileType = archive.ar;
896 | path = "libdouble-conversion.a";
897 | remoteRef = 2DF0FFE82056DD460020B375 /* PBXContainerItemProxy */;
898 | sourceTree = BUILT_PRODUCTS_DIR;
899 | };
900 | 2DF0FFEB2056DD460020B375 /* libprivatedata.a */ = {
901 | isa = PBXReferenceProxy;
902 | fileType = archive.ar;
903 | path = libprivatedata.a;
904 | remoteRef = 2DF0FFEA2056DD460020B375 /* PBXContainerItemProxy */;
905 | sourceTree = BUILT_PRODUCTS_DIR;
906 | };
907 | 2DF0FFED2056DD460020B375 /* libprivatedata-tvOS.a */ = {
908 | isa = PBXReferenceProxy;
909 | fileType = archive.ar;
910 | path = "libprivatedata-tvOS.a";
911 | remoteRef = 2DF0FFEC2056DD460020B375 /* PBXContainerItemProxy */;
912 | sourceTree = BUILT_PRODUCTS_DIR;
913 | };
914 | 3DAD3E841DF850E9000B6D8A /* libRCTImage-tvOS.a */ = {
915 | isa = PBXReferenceProxy;
916 | fileType = archive.ar;
917 | path = "libRCTImage-tvOS.a";
918 | remoteRef = 3DAD3E831DF850E9000B6D8A /* PBXContainerItemProxy */;
919 | sourceTree = BUILT_PRODUCTS_DIR;
920 | };
921 | 3DAD3E881DF850E9000B6D8A /* libRCTLinking-tvOS.a */ = {
922 | isa = PBXReferenceProxy;
923 | fileType = archive.ar;
924 | path = "libRCTLinking-tvOS.a";
925 | remoteRef = 3DAD3E871DF850E9000B6D8A /* PBXContainerItemProxy */;
926 | sourceTree = BUILT_PRODUCTS_DIR;
927 | };
928 | 3DAD3E8C1DF850E9000B6D8A /* libRCTNetwork-tvOS.a */ = {
929 | isa = PBXReferenceProxy;
930 | fileType = archive.ar;
931 | path = "libRCTNetwork-tvOS.a";
932 | remoteRef = 3DAD3E8B1DF850E9000B6D8A /* PBXContainerItemProxy */;
933 | sourceTree = BUILT_PRODUCTS_DIR;
934 | };
935 | 3DAD3E901DF850E9000B6D8A /* libRCTSettings-tvOS.a */ = {
936 | isa = PBXReferenceProxy;
937 | fileType = archive.ar;
938 | path = "libRCTSettings-tvOS.a";
939 | remoteRef = 3DAD3E8F1DF850E9000B6D8A /* PBXContainerItemProxy */;
940 | sourceTree = BUILT_PRODUCTS_DIR;
941 | };
942 | 3DAD3E941DF850E9000B6D8A /* libRCTText-tvOS.a */ = {
943 | isa = PBXReferenceProxy;
944 | fileType = archive.ar;
945 | path = "libRCTText-tvOS.a";
946 | remoteRef = 3DAD3E931DF850E9000B6D8A /* PBXContainerItemProxy */;
947 | sourceTree = BUILT_PRODUCTS_DIR;
948 | };
949 | 3DAD3E991DF850E9000B6D8A /* libRCTWebSocket-tvOS.a */ = {
950 | isa = PBXReferenceProxy;
951 | fileType = archive.ar;
952 | path = "libRCTWebSocket-tvOS.a";
953 | remoteRef = 3DAD3E981DF850E9000B6D8A /* PBXContainerItemProxy */;
954 | sourceTree = BUILT_PRODUCTS_DIR;
955 | };
956 | 3DAD3EA31DF850E9000B6D8A /* libReact.a */ = {
957 | isa = PBXReferenceProxy;
958 | fileType = archive.ar;
959 | path = libReact.a;
960 | remoteRef = 3DAD3EA21DF850E9000B6D8A /* PBXContainerItemProxy */;
961 | sourceTree = BUILT_PRODUCTS_DIR;
962 | };
963 | 3DAD3EA51DF850E9000B6D8A /* libyoga.a */ = {
964 | isa = PBXReferenceProxy;
965 | fileType = archive.ar;
966 | path = libyoga.a;
967 | remoteRef = 3DAD3EA41DF850E9000B6D8A /* PBXContainerItemProxy */;
968 | sourceTree = BUILT_PRODUCTS_DIR;
969 | };
970 | 3DAD3EA71DF850E9000B6D8A /* libyoga.a */ = {
971 | isa = PBXReferenceProxy;
972 | fileType = archive.ar;
973 | path = libyoga.a;
974 | remoteRef = 3DAD3EA61DF850E9000B6D8A /* PBXContainerItemProxy */;
975 | sourceTree = BUILT_PRODUCTS_DIR;
976 | };
977 | 3DAD3EA91DF850E9000B6D8A /* libcxxreact.a */ = {
978 | isa = PBXReferenceProxy;
979 | fileType = archive.ar;
980 | path = libcxxreact.a;
981 | remoteRef = 3DAD3EA81DF850E9000B6D8A /* PBXContainerItemProxy */;
982 | sourceTree = BUILT_PRODUCTS_DIR;
983 | };
984 | 3DAD3EAB1DF850E9000B6D8A /* libcxxreact.a */ = {
985 | isa = PBXReferenceProxy;
986 | fileType = archive.ar;
987 | path = libcxxreact.a;
988 | remoteRef = 3DAD3EAA1DF850E9000B6D8A /* PBXContainerItemProxy */;
989 | sourceTree = BUILT_PRODUCTS_DIR;
990 | };
991 | 3DAD3EAD1DF850E9000B6D8A /* libjschelpers.a */ = {
992 | isa = PBXReferenceProxy;
993 | fileType = archive.ar;
994 | path = libjschelpers.a;
995 | remoteRef = 3DAD3EAC1DF850E9000B6D8A /* PBXContainerItemProxy */;
996 | sourceTree = BUILT_PRODUCTS_DIR;
997 | };
998 | 3DAD3EAF1DF850E9000B6D8A /* libjschelpers.a */ = {
999 | isa = PBXReferenceProxy;
1000 | fileType = archive.ar;
1001 | path = libjschelpers.a;
1002 | remoteRef = 3DAD3EAE1DF850E9000B6D8A /* PBXContainerItemProxy */;
1003 | sourceTree = BUILT_PRODUCTS_DIR;
1004 | };
1005 | 5E9157331DD0AC6500FF2AA8 /* libRCTAnimation.a */ = {
1006 | isa = PBXReferenceProxy;
1007 | fileType = archive.ar;
1008 | path = libRCTAnimation.a;
1009 | remoteRef = 5E9157321DD0AC6500FF2AA8 /* PBXContainerItemProxy */;
1010 | sourceTree = BUILT_PRODUCTS_DIR;
1011 | };
1012 | 5E9157351DD0AC6500FF2AA8 /* libRCTAnimation.a */ = {
1013 | isa = PBXReferenceProxy;
1014 | fileType = archive.ar;
1015 | path = libRCTAnimation.a;
1016 | remoteRef = 5E9157341DD0AC6500FF2AA8 /* PBXContainerItemProxy */;
1017 | sourceTree = BUILT_PRODUCTS_DIR;
1018 | };
1019 | 78C398B91ACF4ADC00677621 /* libRCTLinking.a */ = {
1020 | isa = PBXReferenceProxy;
1021 | fileType = archive.ar;
1022 | path = libRCTLinking.a;
1023 | remoteRef = 78C398B81ACF4ADC00677621 /* PBXContainerItemProxy */;
1024 | sourceTree = BUILT_PRODUCTS_DIR;
1025 | };
1026 | 832341B51AAA6A8300B99B32 /* libRCTText.a */ = {
1027 | isa = PBXReferenceProxy;
1028 | fileType = archive.ar;
1029 | path = libRCTText.a;
1030 | remoteRef = 832341B41AAA6A8300B99B32 /* PBXContainerItemProxy */;
1031 | sourceTree = BUILT_PRODUCTS_DIR;
1032 | };
1033 | ADBDB9271DFEBF0700ED6528 /* libRCTBlob.a */ = {
1034 | isa = PBXReferenceProxy;
1035 | fileType = archive.ar;
1036 | path = libRCTBlob.a;
1037 | remoteRef = ADBDB9261DFEBF0700ED6528 /* PBXContainerItemProxy */;
1038 | sourceTree = BUILT_PRODUCTS_DIR;
1039 | };
1040 | /* End PBXReferenceProxy section */
1041 |
1042 | /* Begin PBXResourcesBuildPhase section */
1043 | 00E356EC1AD99517003FC87E /* Resources */ = {
1044 | isa = PBXResourcesBuildPhase;
1045 | buildActionMask = 2147483647;
1046 | files = (
1047 | );
1048 | runOnlyForDeploymentPostprocessing = 0;
1049 | };
1050 | 13B07F8E1A680F5B00A75B9A /* Resources */ = {
1051 | isa = PBXResourcesBuildPhase;
1052 | buildActionMask = 2147483647;
1053 | files = (
1054 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */,
1055 | 13B07FBD1A68108700A75B9A /* LaunchScreen.xib in Resources */,
1056 | );
1057 | runOnlyForDeploymentPostprocessing = 0;
1058 | };
1059 | 2D02E4791E0B4A5D006451C7 /* Resources */ = {
1060 | isa = PBXResourcesBuildPhase;
1061 | buildActionMask = 2147483647;
1062 | files = (
1063 | 2D02E4BD1E0B4A84006451C7 /* Images.xcassets in Resources */,
1064 | );
1065 | runOnlyForDeploymentPostprocessing = 0;
1066 | };
1067 | 2D02E48E1E0B4A5D006451C7 /* Resources */ = {
1068 | isa = PBXResourcesBuildPhase;
1069 | buildActionMask = 2147483647;
1070 | files = (
1071 | );
1072 | runOnlyForDeploymentPostprocessing = 0;
1073 | };
1074 | /* End PBXResourcesBuildPhase section */
1075 |
1076 | /* Begin PBXShellScriptBuildPhase section */
1077 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = {
1078 | isa = PBXShellScriptBuildPhase;
1079 | buildActionMask = 2147483647;
1080 | files = (
1081 | );
1082 | inputPaths = (
1083 | );
1084 | name = "Bundle React Native code and images";
1085 | outputPaths = (
1086 | );
1087 | runOnlyForDeploymentPostprocessing = 0;
1088 | shellPath = /bin/sh;
1089 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
1090 | };
1091 | 2D02E4CB1E0B4B27006451C7 /* Bundle React Native Code And Images */ = {
1092 | isa = PBXShellScriptBuildPhase;
1093 | buildActionMask = 2147483647;
1094 | files = (
1095 | );
1096 | inputPaths = (
1097 | );
1098 | name = "Bundle React Native Code And Images";
1099 | outputPaths = (
1100 | );
1101 | runOnlyForDeploymentPostprocessing = 0;
1102 | shellPath = /bin/sh;
1103 | shellScript = "export NODE_BINARY=node\n../node_modules/react-native/scripts/react-native-xcode.sh";
1104 | };
1105 | /* End PBXShellScriptBuildPhase section */
1106 |
1107 | /* Begin PBXSourcesBuildPhase section */
1108 | 00E356EA1AD99517003FC87E /* Sources */ = {
1109 | isa = PBXSourcesBuildPhase;
1110 | buildActionMask = 2147483647;
1111 | files = (
1112 | 00E356F31AD99517003FC87E /* exampleTests.m in Sources */,
1113 | );
1114 | runOnlyForDeploymentPostprocessing = 0;
1115 | };
1116 | 13B07F871A680F5B00A75B9A /* Sources */ = {
1117 | isa = PBXSourcesBuildPhase;
1118 | buildActionMask = 2147483647;
1119 | files = (
1120 | 13B07FBC1A68108700A75B9A /* AppDelegate.m in Sources */,
1121 | 13B07FC11A68108700A75B9A /* main.m in Sources */,
1122 | );
1123 | runOnlyForDeploymentPostprocessing = 0;
1124 | };
1125 | 2D02E4771E0B4A5D006451C7 /* Sources */ = {
1126 | isa = PBXSourcesBuildPhase;
1127 | buildActionMask = 2147483647;
1128 | files = (
1129 | 2D02E4BF1E0B4AB3006451C7 /* main.m in Sources */,
1130 | 2D02E4BC1E0B4A80006451C7 /* AppDelegate.m in Sources */,
1131 | );
1132 | runOnlyForDeploymentPostprocessing = 0;
1133 | };
1134 | 2D02E48C1E0B4A5D006451C7 /* Sources */ = {
1135 | isa = PBXSourcesBuildPhase;
1136 | buildActionMask = 2147483647;
1137 | files = (
1138 | 2DCD954D1E0B4F2C00145EB5 /* exampleTests.m in Sources */,
1139 | );
1140 | runOnlyForDeploymentPostprocessing = 0;
1141 | };
1142 | /* End PBXSourcesBuildPhase section */
1143 |
1144 | /* Begin PBXTargetDependency section */
1145 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = {
1146 | isa = PBXTargetDependency;
1147 | target = 13B07F861A680F5B00A75B9A /* example */;
1148 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */;
1149 | };
1150 | 2D02E4921E0B4A5D006451C7 /* PBXTargetDependency */ = {
1151 | isa = PBXTargetDependency;
1152 | target = 2D02E47A1E0B4A5D006451C7 /* example-tvOS */;
1153 | targetProxy = 2D02E4911E0B4A5D006451C7 /* PBXContainerItemProxy */;
1154 | };
1155 | /* End PBXTargetDependency section */
1156 |
1157 | /* Begin PBXVariantGroup section */
1158 | 13B07FB11A68108700A75B9A /* LaunchScreen.xib */ = {
1159 | isa = PBXVariantGroup;
1160 | children = (
1161 | 13B07FB21A68108700A75B9A /* Base */,
1162 | );
1163 | name = LaunchScreen.xib;
1164 | path = example;
1165 | sourceTree = "";
1166 | };
1167 | /* End PBXVariantGroup section */
1168 |
1169 | /* Begin XCBuildConfiguration section */
1170 | 00E356F61AD99517003FC87E /* Debug */ = {
1171 | isa = XCBuildConfiguration;
1172 | buildSettings = {
1173 | BUNDLE_LOADER = "$(TEST_HOST)";
1174 | GCC_PREPROCESSOR_DEFINITIONS = (
1175 | "DEBUG=1",
1176 | "$(inherited)",
1177 | );
1178 | INFOPLIST_FILE = exampleTests/Info.plist;
1179 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
1180 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
1181 | OTHER_LDFLAGS = (
1182 | "-ObjC",
1183 | "-lc++",
1184 | );
1185 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
1186 | PRODUCT_NAME = "$(TARGET_NAME)";
1187 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example";
1188 | LIBRARY_SEARCH_PATHS = (
1189 | "$(inherited)",
1190 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1191 | );
1192 | HEADER_SEARCH_PATHS = (
1193 | "$(inherited)",
1194 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1195 | );
1196 | };
1197 | name = Debug;
1198 | };
1199 | 00E356F71AD99517003FC87E /* Release */ = {
1200 | isa = XCBuildConfiguration;
1201 | buildSettings = {
1202 | BUNDLE_LOADER = "$(TEST_HOST)";
1203 | COPY_PHASE_STRIP = NO;
1204 | INFOPLIST_FILE = exampleTests/Info.plist;
1205 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
1206 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
1207 | OTHER_LDFLAGS = (
1208 | "-ObjC",
1209 | "-lc++",
1210 | );
1211 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
1212 | PRODUCT_NAME = "$(TARGET_NAME)";
1213 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example.app/example";
1214 | LIBRARY_SEARCH_PATHS = (
1215 | "$(inherited)",
1216 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1217 | );
1218 | HEADER_SEARCH_PATHS = (
1219 | "$(inherited)",
1220 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1221 | );
1222 | };
1223 | name = Release;
1224 | };
1225 | 13B07F941A680F5B00A75B9A /* Debug */ = {
1226 | isa = XCBuildConfiguration;
1227 | buildSettings = {
1228 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
1229 | CURRENT_PROJECT_VERSION = 1;
1230 | DEAD_CODE_STRIPPING = NO;
1231 | INFOPLIST_FILE = example/Info.plist;
1232 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
1233 | OTHER_LDFLAGS = (
1234 | "$(inherited)",
1235 | "-ObjC",
1236 | "-lc++",
1237 | );
1238 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
1239 | PRODUCT_NAME = example;
1240 | VERSIONING_SYSTEM = "apple-generic";
1241 | HEADER_SEARCH_PATHS = (
1242 | "$(inherited)",
1243 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1244 | );
1245 | };
1246 | name = Debug;
1247 | };
1248 | 13B07F951A680F5B00A75B9A /* Release */ = {
1249 | isa = XCBuildConfiguration;
1250 | buildSettings = {
1251 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
1252 | CURRENT_PROJECT_VERSION = 1;
1253 | INFOPLIST_FILE = example/Info.plist;
1254 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
1255 | OTHER_LDFLAGS = (
1256 | "$(inherited)",
1257 | "-ObjC",
1258 | "-lc++",
1259 | );
1260 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)";
1261 | PRODUCT_NAME = example;
1262 | VERSIONING_SYSTEM = "apple-generic";
1263 | HEADER_SEARCH_PATHS = (
1264 | "$(inherited)",
1265 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1266 | );
1267 | };
1268 | name = Release;
1269 | };
1270 | 2D02E4971E0B4A5E006451C7 /* Debug */ = {
1271 | isa = XCBuildConfiguration;
1272 | buildSettings = {
1273 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image";
1274 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
1275 | CLANG_ANALYZER_NONNULL = YES;
1276 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
1277 | CLANG_WARN_INFINITE_RECURSION = YES;
1278 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1279 | DEBUG_INFORMATION_FORMAT = dwarf;
1280 | ENABLE_TESTABILITY = YES;
1281 | GCC_NO_COMMON_BLOCKS = YES;
1282 | INFOPLIST_FILE = "example-tvOS/Info.plist";
1283 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
1284 | OTHER_LDFLAGS = (
1285 | "-ObjC",
1286 | "-lc++",
1287 | );
1288 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOS";
1289 | PRODUCT_NAME = "$(TARGET_NAME)";
1290 | SDKROOT = appletvos;
1291 | TARGETED_DEVICE_FAMILY = 3;
1292 | TVOS_DEPLOYMENT_TARGET = 9.2;
1293 | LIBRARY_SEARCH_PATHS = (
1294 | "$(inherited)",
1295 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1296 | );
1297 | HEADER_SEARCH_PATHS = (
1298 | "$(inherited)",
1299 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1300 | );
1301 | };
1302 | name = Debug;
1303 | };
1304 | 2D02E4981E0B4A5E006451C7 /* Release */ = {
1305 | isa = XCBuildConfiguration;
1306 | buildSettings = {
1307 | ASSETCATALOG_COMPILER_APPICON_NAME = "App Icon & Top Shelf Image";
1308 | ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
1309 | CLANG_ANALYZER_NONNULL = YES;
1310 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
1311 | CLANG_WARN_INFINITE_RECURSION = YES;
1312 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1313 | COPY_PHASE_STRIP = NO;
1314 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
1315 | GCC_NO_COMMON_BLOCKS = YES;
1316 | INFOPLIST_FILE = "example-tvOS/Info.plist";
1317 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
1318 | OTHER_LDFLAGS = (
1319 | "-ObjC",
1320 | "-lc++",
1321 | );
1322 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOS";
1323 | PRODUCT_NAME = "$(TARGET_NAME)";
1324 | SDKROOT = appletvos;
1325 | TARGETED_DEVICE_FAMILY = 3;
1326 | TVOS_DEPLOYMENT_TARGET = 9.2;
1327 | LIBRARY_SEARCH_PATHS = (
1328 | "$(inherited)",
1329 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1330 | );
1331 | HEADER_SEARCH_PATHS = (
1332 | "$(inherited)",
1333 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1334 | );
1335 | };
1336 | name = Release;
1337 | };
1338 | 2D02E4991E0B4A5E006451C7 /* Debug */ = {
1339 | isa = XCBuildConfiguration;
1340 | buildSettings = {
1341 | BUNDLE_LOADER = "$(TEST_HOST)";
1342 | CLANG_ANALYZER_NONNULL = YES;
1343 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
1344 | CLANG_WARN_INFINITE_RECURSION = YES;
1345 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1346 | DEBUG_INFORMATION_FORMAT = dwarf;
1347 | ENABLE_TESTABILITY = YES;
1348 | GCC_NO_COMMON_BLOCKS = YES;
1349 | INFOPLIST_FILE = "example-tvOSTests/Info.plist";
1350 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
1351 | OTHER_LDFLAGS = (
1352 | "-ObjC",
1353 | "-lc++",
1354 | );
1355 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOSTests";
1356 | PRODUCT_NAME = "$(TARGET_NAME)";
1357 | SDKROOT = appletvos;
1358 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example-tvOS.app/example-tvOS";
1359 | TVOS_DEPLOYMENT_TARGET = 10.1;
1360 | LIBRARY_SEARCH_PATHS = (
1361 | "$(inherited)",
1362 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1363 | );
1364 | HEADER_SEARCH_PATHS = (
1365 | "$(inherited)",
1366 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1367 | );
1368 | };
1369 | name = Debug;
1370 | };
1371 | 2D02E49A1E0B4A5E006451C7 /* Release */ = {
1372 | isa = XCBuildConfiguration;
1373 | buildSettings = {
1374 | BUNDLE_LOADER = "$(TEST_HOST)";
1375 | CLANG_ANALYZER_NONNULL = YES;
1376 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
1377 | CLANG_WARN_INFINITE_RECURSION = YES;
1378 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1379 | COPY_PHASE_STRIP = NO;
1380 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
1381 | GCC_NO_COMMON_BLOCKS = YES;
1382 | INFOPLIST_FILE = "example-tvOSTests/Info.plist";
1383 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
1384 | OTHER_LDFLAGS = (
1385 | "-ObjC",
1386 | "-lc++",
1387 | );
1388 | PRODUCT_BUNDLE_IDENTIFIER = "com.facebook.REACT.example-tvOSTests";
1389 | PRODUCT_NAME = "$(TARGET_NAME)";
1390 | SDKROOT = appletvos;
1391 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/example-tvOS.app/example-tvOS";
1392 | TVOS_DEPLOYMENT_TARGET = 10.1;
1393 | LIBRARY_SEARCH_PATHS = (
1394 | "$(inherited)",
1395 | "\"$(SRCROOT)/$(TARGET_NAME)\"",
1396 | );
1397 | HEADER_SEARCH_PATHS = (
1398 | "$(inherited)",
1399 | "$(SRCROOT)/../node_modules/react-native-directed-scrollview/ios/RCTDirectedScrollView/**",
1400 | );
1401 | };
1402 | name = Release;
1403 | };
1404 | 83CBBA201A601CBA00E9B192 /* Debug */ = {
1405 | isa = XCBuildConfiguration;
1406 | buildSettings = {
1407 | ALWAYS_SEARCH_USER_PATHS = NO;
1408 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
1409 | CLANG_CXX_LIBRARY = "libc++";
1410 | CLANG_ENABLE_MODULES = YES;
1411 | CLANG_ENABLE_OBJC_ARC = YES;
1412 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
1413 | CLANG_WARN_BOOL_CONVERSION = YES;
1414 | CLANG_WARN_COMMA = YES;
1415 | CLANG_WARN_CONSTANT_CONVERSION = YES;
1416 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
1417 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
1418 | CLANG_WARN_EMPTY_BODY = YES;
1419 | CLANG_WARN_ENUM_CONVERSION = YES;
1420 | CLANG_WARN_INFINITE_RECURSION = YES;
1421 | CLANG_WARN_INT_CONVERSION = YES;
1422 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
1423 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
1424 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
1425 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
1426 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
1427 | CLANG_WARN_STRICT_PROTOTYPES = YES;
1428 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1429 | CLANG_WARN_UNREACHABLE_CODE = YES;
1430 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
1431 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
1432 | COPY_PHASE_STRIP = NO;
1433 | ENABLE_STRICT_OBJC_MSGSEND = YES;
1434 | ENABLE_TESTABILITY = YES;
1435 | GCC_C_LANGUAGE_STANDARD = gnu99;
1436 | GCC_DYNAMIC_NO_PIC = NO;
1437 | GCC_NO_COMMON_BLOCKS = YES;
1438 | GCC_OPTIMIZATION_LEVEL = 0;
1439 | GCC_PREPROCESSOR_DEFINITIONS = (
1440 | "DEBUG=1",
1441 | "$(inherited)",
1442 | );
1443 | GCC_SYMBOLS_PRIVATE_EXTERN = NO;
1444 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
1445 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
1446 | GCC_WARN_UNDECLARED_SELECTOR = YES;
1447 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
1448 | GCC_WARN_UNUSED_FUNCTION = YES;
1449 | GCC_WARN_UNUSED_VARIABLE = YES;
1450 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
1451 | MTL_ENABLE_DEBUG_INFO = YES;
1452 | ONLY_ACTIVE_ARCH = YES;
1453 | SDKROOT = iphoneos;
1454 | };
1455 | name = Debug;
1456 | };
1457 | 83CBBA211A601CBA00E9B192 /* Release */ = {
1458 | isa = XCBuildConfiguration;
1459 | buildSettings = {
1460 | ALWAYS_SEARCH_USER_PATHS = NO;
1461 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
1462 | CLANG_CXX_LIBRARY = "libc++";
1463 | CLANG_ENABLE_MODULES = YES;
1464 | CLANG_ENABLE_OBJC_ARC = YES;
1465 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
1466 | CLANG_WARN_BOOL_CONVERSION = YES;
1467 | CLANG_WARN_COMMA = YES;
1468 | CLANG_WARN_CONSTANT_CONVERSION = YES;
1469 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES;
1470 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
1471 | CLANG_WARN_EMPTY_BODY = YES;
1472 | CLANG_WARN_ENUM_CONVERSION = YES;
1473 | CLANG_WARN_INFINITE_RECURSION = YES;
1474 | CLANG_WARN_INT_CONVERSION = YES;
1475 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
1476 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES;
1477 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
1478 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
1479 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
1480 | CLANG_WARN_STRICT_PROTOTYPES = YES;
1481 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
1482 | CLANG_WARN_UNREACHABLE_CODE = YES;
1483 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
1484 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
1485 | COPY_PHASE_STRIP = YES;
1486 | ENABLE_NS_ASSERTIONS = NO;
1487 | ENABLE_STRICT_OBJC_MSGSEND = YES;
1488 | GCC_C_LANGUAGE_STANDARD = gnu99;
1489 | GCC_NO_COMMON_BLOCKS = YES;
1490 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
1491 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
1492 | GCC_WARN_UNDECLARED_SELECTOR = YES;
1493 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
1494 | GCC_WARN_UNUSED_FUNCTION = YES;
1495 | GCC_WARN_UNUSED_VARIABLE = YES;
1496 | IPHONEOS_DEPLOYMENT_TARGET = 9.0;
1497 | MTL_ENABLE_DEBUG_INFO = NO;
1498 | SDKROOT = iphoneos;
1499 | VALIDATE_PRODUCT = YES;
1500 | };
1501 | name = Release;
1502 | };
1503 | /* End XCBuildConfiguration section */
1504 |
1505 | /* Begin XCConfigurationList section */
1506 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "exampleTests" */ = {
1507 | isa = XCConfigurationList;
1508 | buildConfigurations = (
1509 | 00E356F61AD99517003FC87E /* Debug */,
1510 | 00E356F71AD99517003FC87E /* Release */,
1511 | );
1512 | defaultConfigurationIsVisible = 0;
1513 | defaultConfigurationName = Release;
1514 | };
1515 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "example" */ = {
1516 | isa = XCConfigurationList;
1517 | buildConfigurations = (
1518 | 13B07F941A680F5B00A75B9A /* Debug */,
1519 | 13B07F951A680F5B00A75B9A /* Release */,
1520 | );
1521 | defaultConfigurationIsVisible = 0;
1522 | defaultConfigurationName = Release;
1523 | };
1524 | 2D02E4BA1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOS" */ = {
1525 | isa = XCConfigurationList;
1526 | buildConfigurations = (
1527 | 2D02E4971E0B4A5E006451C7 /* Debug */,
1528 | 2D02E4981E0B4A5E006451C7 /* Release */,
1529 | );
1530 | defaultConfigurationIsVisible = 0;
1531 | defaultConfigurationName = Release;
1532 | };
1533 | 2D02E4BB1E0B4A5E006451C7 /* Build configuration list for PBXNativeTarget "example-tvOSTests" */ = {
1534 | isa = XCConfigurationList;
1535 | buildConfigurations = (
1536 | 2D02E4991E0B4A5E006451C7 /* Debug */,
1537 | 2D02E49A1E0B4A5E006451C7 /* Release */,
1538 | );
1539 | defaultConfigurationIsVisible = 0;
1540 | defaultConfigurationName = Release;
1541 | };
1542 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "example" */ = {
1543 | isa = XCConfigurationList;
1544 | buildConfigurations = (
1545 | 83CBBA201A601CBA00E9B192 /* Debug */,
1546 | 83CBBA211A601CBA00E9B192 /* Release */,
1547 | );
1548 | defaultConfigurationIsVisible = 0;
1549 | defaultConfigurationName = Release;
1550 | };
1551 | /* End XCConfigurationList section */
1552 | };
1553 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */;
1554 | }
1555 |
--------------------------------------------------------------------------------
/example/ios/example.xcodeproj/xcshareddata/xcschemes/example-tvOS.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
29 |
35 |
36 |
37 |
43 |
49 |
50 |
51 |
52 |
53 |
58 |
59 |
61 |
67 |
68 |
69 |
70 |
71 |
77 |
78 |
79 |
80 |
81 |
82 |
92 |
94 |
100 |
101 |
102 |
103 |
104 |
105 |
111 |
113 |
119 |
120 |
121 |
122 |
124 |
125 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/example/ios/example.xcodeproj/xcshareddata/xcschemes/example.xcscheme:
--------------------------------------------------------------------------------
1 |
2 |
5 |
8 |
9 |
15 |
21 |
22 |
23 |
29 |
35 |
36 |
37 |
43 |
49 |
50 |
51 |
52 |
53 |
58 |
59 |
61 |
67 |
68 |
69 |
70 |
71 |
77 |
78 |
79 |
80 |
81 |
82 |
92 |
94 |
100 |
101 |
102 |
103 |
104 |
105 |
111 |
113 |
119 |
120 |
121 |
122 |
124 |
125 |
128 |
129 |
130 |
--------------------------------------------------------------------------------
/example/ios/example/AppDelegate.h:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | #import
9 |
10 | @interface AppDelegate : UIResponder
11 |
12 | @property (nonatomic, strong) UIWindow *window;
13 |
14 | @end
15 |
--------------------------------------------------------------------------------
/example/ios/example/AppDelegate.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | #import "AppDelegate.h"
9 |
10 | #import
11 | #import
12 |
13 | @implementation AppDelegate
14 |
15 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
16 | {
17 | NSURL *jsCodeLocation;
18 |
19 | #ifdef DEBUG
20 | jsCodeLocation = [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index" fallbackResource:nil];
21 | #else
22 | jsCodeLocation = [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"];
23 | #endif
24 |
25 | RCTRootView *rootView = [[RCTRootView alloc] initWithBundleURL:jsCodeLocation
26 | moduleName:@"example"
27 | initialProperties:nil
28 | launchOptions:launchOptions];
29 | rootView.backgroundColor = [[UIColor alloc] initWithRed:1.0f green:1.0f blue:1.0f alpha:1];
30 |
31 | self.window = [[UIWindow alloc] initWithFrame:[UIScreen mainScreen].bounds];
32 | UIViewController *rootViewController = [UIViewController new];
33 | rootViewController.view = rootView;
34 | self.window.rootViewController = rootViewController;
35 | [self.window makeKeyAndVisible];
36 | return YES;
37 | }
38 |
39 | @end
40 |
--------------------------------------------------------------------------------
/example/ios/example/Base.lproj/LaunchScreen.xib:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
21 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
--------------------------------------------------------------------------------
/example/ios/example/Images.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "29x29",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "29x29",
11 | "scale" : "3x"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "size" : "40x40",
16 | "scale" : "2x"
17 | },
18 | {
19 | "idiom" : "iphone",
20 | "size" : "40x40",
21 | "scale" : "3x"
22 | },
23 | {
24 | "idiom" : "iphone",
25 | "size" : "60x60",
26 | "scale" : "2x"
27 | },
28 | {
29 | "idiom" : "iphone",
30 | "size" : "60x60",
31 | "scale" : "3x"
32 | }
33 | ],
34 | "info" : {
35 | "version" : 1,
36 | "author" : "xcode"
37 | }
38 | }
--------------------------------------------------------------------------------
/example/ios/example/Images.xcassets/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "info" : {
3 | "version" : 1,
4 | "author" : "xcode"
5 | }
6 | }
7 |
--------------------------------------------------------------------------------
/example/ios/example/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleDisplayName
8 | example
9 | CFBundleExecutable
10 | $(EXECUTABLE_NAME)
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | $(PRODUCT_NAME)
17 | CFBundlePackageType
18 | APPL
19 | CFBundleShortVersionString
20 | 1.0
21 | CFBundleSignature
22 | ????
23 | CFBundleVersion
24 | 1
25 | LSRequiresIPhoneOS
26 |
27 | NSLocationWhenInUseUsageDescription
28 |
29 | UILaunchStoryboardName
30 | LaunchScreen
31 | UIRequiredDeviceCapabilities
32 |
33 | armv7
34 |
35 | UISupportedInterfaceOrientations
36 |
37 | UIInterfaceOrientationPortrait
38 | UIInterfaceOrientationLandscapeLeft
39 | UIInterfaceOrientationLandscapeRight
40 |
41 | UIViewControllerBasedStatusBarAppearance
42 |
43 | NSLocationWhenInUseUsageDescription
44 |
45 | NSAppTransportSecurity
46 |
47 |
48 | NSAllowsArbitraryLoads
49 |
50 | NSExceptionDomains
51 |
52 | localhost
53 |
54 | NSExceptionAllowsInsecureHTTPLoads
55 |
56 |
57 |
58 |
59 |
60 |
61 |
--------------------------------------------------------------------------------
/example/ios/example/main.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | #import
9 |
10 | #import "AppDelegate.h"
11 |
12 | int main(int argc, char * argv[]) {
13 | @autoreleasepool {
14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/example/ios/exampleTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | en
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleSignature
20 | ????
21 | CFBundleVersion
22 | 1
23 |
24 |
25 |
--------------------------------------------------------------------------------
/example/ios/exampleTests/exampleTests.m:
--------------------------------------------------------------------------------
1 | /**
2 | * Copyright (c) 2015-present, Facebook, Inc.
3 | *
4 | * This source code is licensed under the MIT license found in the
5 | * LICENSE file in the root directory of this source tree.
6 | */
7 |
8 | #import
9 | #import
10 |
11 | #import
12 | #import
13 |
14 | #define TIMEOUT_SECONDS 600
15 | #define TEXT_TO_LOOK_FOR @"Welcome to React Native!"
16 |
17 | @interface exampleTests : XCTestCase
18 |
19 | @end
20 |
21 | @implementation exampleTests
22 |
23 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL(^)(UIView *view))test
24 | {
25 | if (test(view)) {
26 | return YES;
27 | }
28 | for (UIView *subview in [view subviews]) {
29 | if ([self findSubviewInView:subview matching:test]) {
30 | return YES;
31 | }
32 | }
33 | return NO;
34 | }
35 |
36 | - (void)testRendersWelcomeScreen
37 | {
38 | UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController];
39 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS];
40 | BOOL foundElement = NO;
41 |
42 | __block NSString *redboxError = nil;
43 | RCTSetLogFunction(^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) {
44 | if (level >= RCTLogLevelError) {
45 | redboxError = message;
46 | }
47 | });
48 |
49 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) {
50 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
51 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]];
52 |
53 | foundElement = [self findSubviewInView:vc.view matching:^BOOL(UIView *view) {
54 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) {
55 | return YES;
56 | }
57 | return NO;
58 | }];
59 | }
60 |
61 | RCTSetLogFunction(RCTDefaultLogFunction);
62 |
63 | XCTAssertNil(redboxError, @"RedBox error: %@", redboxError);
64 | XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS);
65 | }
66 |
67 |
68 | @end
69 |
--------------------------------------------------------------------------------
/example/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "example",
3 | "version": "0.0.1",
4 | "private": true,
5 | "scripts": {
6 | "start": "node node_modules/react-native/local-cli/cli.js start",
7 | "test": "jest"
8 | },
9 | "dependencies": {
10 | "react": "16.6.3",
11 | "react-native": "0.57.8",
12 | "react-native-directed-scrollview": "git+https://github.com/chrisfisher/react-native-directed-scrollview.git#master"
13 | },
14 | "devDependencies": {
15 | "babel-jest": "23.6.0",
16 | "jest": "23.6.0",
17 | "metro-react-native-babel-preset": "0.48.5",
18 | "react-test-renderer": "16.6.3"
19 | },
20 | "jest": {
21 | "preset": "react-native"
22 | }
23 | }
24 |
--------------------------------------------------------------------------------
/example/rnds-demo.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/chrisfisher/react-native-directed-scrollview/9c92388c5c8c2a07f34618ae5800e1fac6562bac/example/rnds-demo.gif
--------------------------------------------------------------------------------
/example/src/colors.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | const colors = {
4 | white: '#fff',
5 | lightGreen: '#8fc15c',
6 | lightGray: '#dadada',
7 | darkPurple: '#690b53',
8 | };
9 |
10 | export default colors;
11 |
--------------------------------------------------------------------------------
/example/src/components/ColumnLabels.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | import React, { Component } from 'react';
4 | import { Text, View, StyleSheet } from 'react-native';
5 | import type { Cell } from '../data';
6 | import colors from '../colors';
7 |
8 | export default class ColumnLabels extends Component {
9 | render() {
10 | return (
11 |
12 | { this.props.cellsByRow[1].cells.map((cell, index) => this._renderColumnLabel(cell, index)) }
13 |
14 | );
15 | }
16 |
17 | _renderColumnLabel(cell: Cell, index: number) {
18 | return (
19 |
20 |
21 | {index + 1}
22 |
23 |
24 | );
25 | }
26 | }
27 |
28 | const styles = StyleSheet.create({
29 | container: {
30 | justifyContent: 'center',
31 | alignItems: 'center',
32 | flexDirection: 'row'
33 | },
34 | columnLabel: {
35 | width: 120,
36 | justifyContent: 'center',
37 | alignItems: 'center',
38 | },
39 | columnTitle: {
40 | backgroundColor: colors.lightGreen,
41 | paddingVertical: 4,
42 | paddingHorizontal: 10,
43 | color: colors.white,
44 | fontWeight: '500',
45 | fontSize: 16,
46 | },
47 | });
48 |
--------------------------------------------------------------------------------
/example/src/components/Grid.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | import React, { Component } from 'react';
4 | import { StyleSheet, View } from 'react-native';
5 | import ScrollView, { ScrollViewChild } from 'react-native-directed-scrollview';
6 | import GridContent from './GridContent';
7 | import RowLabels from './RowLabels';
8 | import ColumnLabels from './ColumnLabels';
9 | import { getCellsByRow } from '../data';
10 |
11 | export default class Grid extends Component {
12 | render() {
13 | const cellsByRow = getCellsByRow();
14 |
15 | return (
16 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 | );
37 | }
38 | }
39 |
40 | const styles = StyleSheet.create({
41 | container: {
42 | flex: 1,
43 | },
44 | contentContainer: {
45 | height: 1080,
46 | width: 1080,
47 | },
48 | rowLabelsContainer: {
49 | position: 'absolute',
50 | left: 0,
51 | top: 0,
52 | bottom: 0,
53 | width: 100,
54 | },
55 | columnLabelsContainer: {
56 | position: 'absolute',
57 | left: 0,
58 | top: 0,
59 | right: 0,
60 | height: 30,
61 | },
62 | });
63 |
--------------------------------------------------------------------------------
/example/src/components/GridContent.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | import React, { Component } from 'react';
4 | import { Text, View, StyleSheet, TouchableOpacity, Alert } from 'react-native';
5 | import type { Row, Cell } from '../data';
6 | import colors from '../colors';
7 |
8 | export default class GridContent extends Component {
9 | props: {
10 | cellsByRow: Array
11 | }
12 |
13 | render() {
14 | return (
15 |
16 | { this.props.cellsByRow.map(row => this._renderRow(row)) }
17 |
18 | );
19 | }
20 |
21 | _renderRow(row: Row) {
22 | return (
23 |
24 | { row.cells.map(cell => this._renderCell(cell)) }
25 |
26 | );
27 | }
28 |
29 | _renderCell(cell: Cell) {
30 | return (
31 | { this._onCellPressed(cell.id); }}
35 | >
36 |
37 | );
38 | }
39 |
40 | _onCellPressed(cellId: string) {
41 | Alert.alert(`Pressed ${cellId}`);
42 | }
43 | }
44 |
45 | const styles = StyleSheet.create({
46 | rowContainer: {
47 | flexDirection: 'row',
48 | },
49 | cellContainer: {
50 | justifyContent: 'center',
51 | alignItems: 'center',
52 | height: 100,
53 | width: 100,
54 | margin: 10,
55 | backgroundColor: colors.lightGray,
56 | },
57 | });
58 |
--------------------------------------------------------------------------------
/example/src/components/RowLabels.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | import React, { Component } from 'react';
4 | import { Text, View, StyleSheet } from 'react-native';
5 | import type { Row, Cell } from '../data';
6 | import colors from '../colors';
7 |
8 | export default class RowLabels extends Component {
9 | render() {
10 | return (
11 |
12 | { this.props.cellsByRow.map(row => this._renderRowLabel(row)) }
13 |
14 | );
15 | }
16 |
17 | _renderRowLabel(row: Row) {
18 | return (
19 |
20 |
21 | Row label
22 |
23 |
24 | )
25 | }
26 | }
27 |
28 | const styles = StyleSheet.create({
29 | container: {
30 | position: 'absolute',
31 | top: 0,
32 | left: 0,
33 | },
34 | rowLabel: {
35 | height: 120,
36 | justifyContent: 'center',
37 | alignItems: 'center',
38 | },
39 | rowTitle: {
40 | backgroundColor: colors.darkPurple,
41 | paddingVertical: 4,
42 | paddingHorizontal: 10,
43 | color: colors.white,
44 | fontWeight: '500',
45 | fontSize: 16,
46 | },
47 | });
48 |
--------------------------------------------------------------------------------
/example/src/data.js:
--------------------------------------------------------------------------------
1 | /* @flow */
2 |
3 | export const getCellsByRow = (): Array => {
4 | const cellsByRow: Array = [];
5 |
6 | for (var rowIndex = 1; rowIndex < 10; rowIndex++) {
7 | let row: Row = {
8 | id: `row-${rowIndex}`,
9 | cells: []
10 | }
11 |
12 | for (var columnIndex = 1; columnIndex < 10; columnIndex++) {
13 | row.cells.push({
14 | id: `cell-${rowIndex}-${columnIndex}`,
15 | title: `Cell`
16 | });
17 | }
18 |
19 | cellsByRow.push(row)
20 | }
21 |
22 | return cellsByRow;
23 | };
24 |
25 | export type Cell = {
26 | id: string;
27 | title: string;
28 | };
29 |
30 | export type Row = {
31 | id: string;
32 | cells: Array;
33 | };
34 |
--------------------------------------------------------------------------------
/index.js:
--------------------------------------------------------------------------------
1 | import React, { Component } from 'react';
2 | import ReactNative, { requireNativeComponent, View, UIManager, StyleSheet, Platform } from 'react-native';
3 | import ScrollResponder from 'react-native/Libraries/Components/ScrollResponder';
4 | import createReactClass from 'create-react-class';
5 |
6 | const NativeScrollView = requireNativeComponent('DirectedScrollView');
7 | const NativeScrollViewChild = requireNativeComponent('DirectedScrollViewChild');
8 |
9 | const ScrollView = createReactClass({
10 | mixins: [ScrollResponder.Mixin],
11 | getInitialState: function() {
12 | return this.scrollResponderMixinGetInitialState();
13 | },
14 | setNativeProps: function(props) {
15 | this._scrollViewRef && this._scrollViewRef.setNativeProps(props);
16 | },
17 | getScrollResponder: function() {
18 | return this;
19 | },
20 | getScrollableNode: function() {
21 | return ReactNative.findNodeHandle(this._scrollViewRef);
22 | },
23 | scrollTo: function({ x, y, animated }) {
24 | UIManager.dispatchViewManagerCommand(
25 | this.getScrollableNode(),
26 | UIManager.DirectedScrollView.Commands.scrollTo,
27 | [x || 0, y || 0, animated !== false],
28 | );
29 | },
30 | zoomToStart: function({ animated }) {
31 | UIManager.dispatchViewManagerCommand(
32 | this.getScrollableNode(),
33 | UIManager.DirectedScrollView.Commands.zoomToStart,
34 | [animated !== false],
35 | );
36 | },
37 | _scrollViewRef: null,
38 | _setScrollViewRef: function(ref) {
39 | this._scrollViewRef = ref;
40 | },
41 | componentDidMount: function() {
42 | setTimeout(() => {
43 | this.zoomToStart({animated: false});
44 | }, 0);
45 | },
46 | render: function() {
47 | return (
48 |
64 |
65 | {this.props.children}
66 |
67 |
68 | );
69 | }
70 | });
71 |
72 | export default ScrollView;
73 |
74 | export const ScrollViewChild = createReactClass({
75 | render: function() {
76 | return (
77 |
78 | {this.props.children}
79 |
80 | );
81 | }
82 | });
83 |
84 | export const scrollViewWillBeginDragging = 'scrollViewWillBeginDragging';
85 |
86 | export const scrollViewDidEndDragging = 'scrollViewDidEndDragging';
87 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 46;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 899B2D951DE4DA9800EFC859 /* DirectedScrollViewManager.h in CopyFiles */ = {isa = PBXBuildFile; fileRef = 899B2D941DE4DA9800EFC859 /* DirectedScrollViewManager.h */; };
11 | 899B2D971DE4DA9800EFC859 /* DirectedScrollViewManager.m in Sources */ = {isa = PBXBuildFile; fileRef = 899B2D961DE4DA9800EFC859 /* DirectedScrollViewManager.m */; };
12 | D8720ACD1E51614100C90CB6 /* DirectedScrollViewChildManager.m in Sources */ = {isa = PBXBuildFile; fileRef = D8720ACC1E51614100C90CB6 /* DirectedScrollViewChildManager.m */; };
13 | /* End PBXBuildFile section */
14 |
15 | /* Begin PBXCopyFilesBuildPhase section */
16 | 899B2D8F1DE4DA9800EFC859 /* CopyFiles */ = {
17 | isa = PBXCopyFilesBuildPhase;
18 | buildActionMask = 2147483647;
19 | dstPath = "include/$(PRODUCT_NAME)";
20 | dstSubfolderSpec = 16;
21 | files = (
22 | 899B2D951DE4DA9800EFC859 /* DirectedScrollViewManager.h in CopyFiles */,
23 | );
24 | runOnlyForDeploymentPostprocessing = 0;
25 | };
26 | /* End PBXCopyFilesBuildPhase section */
27 |
28 | /* Begin PBXFileReference section */
29 | 899B2D911DE4DA9800EFC859 /* libRCTDirectedScrollView.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = libRCTDirectedScrollView.a; sourceTree = BUILT_PRODUCTS_DIR; };
30 | 899B2D941DE4DA9800EFC859 /* DirectedScrollViewManager.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = DirectedScrollViewManager.h; sourceTree = ""; };
31 | 899B2D961DE4DA9800EFC859 /* DirectedScrollViewManager.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DirectedScrollViewManager.m; sourceTree = ""; };
32 | D8720ACB1E51614100C90CB6 /* DirectedScrollViewChildManager.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DirectedScrollViewChildManager.h; sourceTree = ""; };
33 | D8720ACC1E51614100C90CB6 /* DirectedScrollViewChildManager.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DirectedScrollViewChildManager.m; sourceTree = ""; };
34 | /* End PBXFileReference section */
35 |
36 | /* Begin PBXFrameworksBuildPhase section */
37 | 899B2D8E1DE4DA9800EFC859 /* Frameworks */ = {
38 | isa = PBXFrameworksBuildPhase;
39 | buildActionMask = 2147483647;
40 | files = (
41 | );
42 | runOnlyForDeploymentPostprocessing = 0;
43 | };
44 | /* End PBXFrameworksBuildPhase section */
45 |
46 | /* Begin PBXGroup section */
47 | 899B2D881DE4DA9800EFC859 = {
48 | isa = PBXGroup;
49 | children = (
50 | 899B2D931DE4DA9800EFC859 /* RCTDirectedScrollView */,
51 | 899B2D921DE4DA9800EFC859 /* Products */,
52 | );
53 | sourceTree = "";
54 | };
55 | 899B2D921DE4DA9800EFC859 /* Products */ = {
56 | isa = PBXGroup;
57 | children = (
58 | 899B2D911DE4DA9800EFC859 /* libRCTDirectedScrollView.a */,
59 | );
60 | name = Products;
61 | sourceTree = "";
62 | };
63 | 899B2D931DE4DA9800EFC859 /* RCTDirectedScrollView */ = {
64 | isa = PBXGroup;
65 | children = (
66 | D8720ACB1E51614100C90CB6 /* DirectedScrollViewChildManager.h */,
67 | D8720ACC1E51614100C90CB6 /* DirectedScrollViewChildManager.m */,
68 | 899B2D941DE4DA9800EFC859 /* DirectedScrollViewManager.h */,
69 | 899B2D961DE4DA9800EFC859 /* DirectedScrollViewManager.m */,
70 | );
71 | path = RCTDirectedScrollView;
72 | sourceTree = "";
73 | };
74 | /* End PBXGroup section */
75 |
76 | /* Begin PBXNativeTarget section */
77 | 899B2D901DE4DA9800EFC859 /* RCTDirectedScrollView */ = {
78 | isa = PBXNativeTarget;
79 | buildConfigurationList = 899B2D9A1DE4DA9800EFC859 /* Build configuration list for PBXNativeTarget "RCTDirectedScrollView" */;
80 | buildPhases = (
81 | 899B2D8D1DE4DA9800EFC859 /* Sources */,
82 | 899B2D8E1DE4DA9800EFC859 /* Frameworks */,
83 | 899B2D8F1DE4DA9800EFC859 /* CopyFiles */,
84 | );
85 | buildRules = (
86 | );
87 | dependencies = (
88 | );
89 | name = RCTDirectedScrollView;
90 | productName = RCTDirectedScrollView;
91 | productReference = 899B2D911DE4DA9800EFC859 /* libRCTDirectedScrollView.a */;
92 | productType = "com.apple.product-type.library.static";
93 | };
94 | /* End PBXNativeTarget section */
95 |
96 | /* Begin PBXProject section */
97 | 899B2D891DE4DA9800EFC859 /* Project object */ = {
98 | isa = PBXProject;
99 | attributes = {
100 | LastUpgradeCheck = 0730;
101 | ORGANIZATIONNAME = "Dept of Architecture";
102 | TargetAttributes = {
103 | 899B2D901DE4DA9800EFC859 = {
104 | CreatedOnToolsVersion = 7.3;
105 | };
106 | };
107 | };
108 | buildConfigurationList = 899B2D8C1DE4DA9800EFC859 /* Build configuration list for PBXProject "RCTDirectedScrollView" */;
109 | compatibilityVersion = "Xcode 3.2";
110 | developmentRegion = English;
111 | hasScannedForEncodings = 0;
112 | knownRegions = (
113 | en,
114 | );
115 | mainGroup = 899B2D881DE4DA9800EFC859;
116 | productRefGroup = 899B2D921DE4DA9800EFC859 /* Products */;
117 | projectDirPath = "";
118 | projectRoot = "";
119 | targets = (
120 | 899B2D901DE4DA9800EFC859 /* RCTDirectedScrollView */,
121 | );
122 | };
123 | /* End PBXProject section */
124 |
125 | /* Begin PBXSourcesBuildPhase section */
126 | 899B2D8D1DE4DA9800EFC859 /* Sources */ = {
127 | isa = PBXSourcesBuildPhase;
128 | buildActionMask = 2147483647;
129 | files = (
130 | D8720ACD1E51614100C90CB6 /* DirectedScrollViewChildManager.m in Sources */,
131 | 899B2D971DE4DA9800EFC859 /* DirectedScrollViewManager.m in Sources */,
132 | );
133 | runOnlyForDeploymentPostprocessing = 0;
134 | };
135 | /* End PBXSourcesBuildPhase section */
136 |
137 | /* Begin XCBuildConfiguration section */
138 | 899B2D981DE4DA9800EFC859 /* Debug */ = {
139 | isa = XCBuildConfiguration;
140 | buildSettings = {
141 | ALWAYS_SEARCH_USER_PATHS = NO;
142 | CLANG_ANALYZER_NONNULL = YES;
143 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
144 | CLANG_CXX_LIBRARY = "libc++";
145 | CLANG_ENABLE_MODULES = YES;
146 | CLANG_ENABLE_OBJC_ARC = YES;
147 | CLANG_WARN_BOOL_CONVERSION = YES;
148 | CLANG_WARN_CONSTANT_CONVERSION = YES;
149 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
150 | CLANG_WARN_EMPTY_BODY = YES;
151 | CLANG_WARN_ENUM_CONVERSION = YES;
152 | CLANG_WARN_INT_CONVERSION = YES;
153 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
154 | CLANG_WARN_UNREACHABLE_CODE = YES;
155 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
156 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
157 | COPY_PHASE_STRIP = NO;
158 | DEBUG_INFORMATION_FORMAT = dwarf;
159 | ENABLE_STRICT_OBJC_MSGSEND = YES;
160 | ENABLE_TESTABILITY = YES;
161 | GCC_C_LANGUAGE_STANDARD = gnu99;
162 | GCC_DYNAMIC_NO_PIC = NO;
163 | GCC_NO_COMMON_BLOCKS = YES;
164 | GCC_OPTIMIZATION_LEVEL = 0;
165 | GCC_PREPROCESSOR_DEFINITIONS = (
166 | "DEBUG=1",
167 | "$(inherited)",
168 | );
169 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
170 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
171 | GCC_WARN_UNDECLARED_SELECTOR = YES;
172 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
173 | GCC_WARN_UNUSED_FUNCTION = YES;
174 | GCC_WARN_UNUSED_VARIABLE = YES;
175 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
176 | MTL_ENABLE_DEBUG_INFO = YES;
177 | ONLY_ACTIVE_ARCH = YES;
178 | SDKROOT = iphoneos;
179 | };
180 | name = Debug;
181 | };
182 | 899B2D991DE4DA9800EFC859 /* Release */ = {
183 | isa = XCBuildConfiguration;
184 | buildSettings = {
185 | ALWAYS_SEARCH_USER_PATHS = NO;
186 | CLANG_ANALYZER_NONNULL = YES;
187 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++0x";
188 | CLANG_CXX_LIBRARY = "libc++";
189 | CLANG_ENABLE_MODULES = YES;
190 | CLANG_ENABLE_OBJC_ARC = YES;
191 | CLANG_WARN_BOOL_CONVERSION = YES;
192 | CLANG_WARN_CONSTANT_CONVERSION = YES;
193 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
194 | CLANG_WARN_EMPTY_BODY = YES;
195 | CLANG_WARN_ENUM_CONVERSION = YES;
196 | CLANG_WARN_INT_CONVERSION = YES;
197 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
198 | CLANG_WARN_UNREACHABLE_CODE = YES;
199 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
200 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
201 | COPY_PHASE_STRIP = NO;
202 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
203 | ENABLE_NS_ASSERTIONS = NO;
204 | ENABLE_STRICT_OBJC_MSGSEND = YES;
205 | GCC_C_LANGUAGE_STANDARD = gnu99;
206 | GCC_NO_COMMON_BLOCKS = YES;
207 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
208 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
209 | GCC_WARN_UNDECLARED_SELECTOR = YES;
210 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
211 | GCC_WARN_UNUSED_FUNCTION = YES;
212 | GCC_WARN_UNUSED_VARIABLE = YES;
213 | IPHONEOS_DEPLOYMENT_TARGET = 9.3;
214 | MTL_ENABLE_DEBUG_INFO = NO;
215 | SDKROOT = iphoneos;
216 | VALIDATE_PRODUCT = YES;
217 | };
218 | name = Release;
219 | };
220 | 899B2D9B1DE4DA9800EFC859 /* Debug */ = {
221 | isa = XCBuildConfiguration;
222 | buildSettings = {
223 | HEADER_SEARCH_PATHS = (
224 | "$(inherited)",
225 | /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
226 | "$(SRCROOT)/../example/node_modules/React/**",
227 | "$(SRCROOT)/../example/node_modules/react-native/React/**",
228 | "$(SRCROOT)/../../React/**",
229 | "$(SRCROOT)/../../react-native/React/**",
230 | );
231 | OTHER_LDFLAGS = "-ObjC";
232 | PRODUCT_NAME = "$(TARGET_NAME)";
233 | SKIP_INSTALL = YES;
234 | };
235 | name = Debug;
236 | };
237 | 899B2D9C1DE4DA9800EFC859 /* Release */ = {
238 | isa = XCBuildConfiguration;
239 | buildSettings = {
240 | HEADER_SEARCH_PATHS = (
241 | "$(inherited)",
242 | /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include,
243 | "$(SRCROOT)/../example/node_modules/React/**",
244 | "$(SRCROOT)/../example/node_modules/react-native/React/**",
245 | "$(SRCROOT)/../../React/**",
246 | "$(SRCROOT)/../../react-native/React/**",
247 | );
248 | OTHER_LDFLAGS = "-ObjC";
249 | PRODUCT_NAME = "$(TARGET_NAME)";
250 | SKIP_INSTALL = YES;
251 | };
252 | name = Release;
253 | };
254 | /* End XCBuildConfiguration section */
255 |
256 | /* Begin XCConfigurationList section */
257 | 899B2D8C1DE4DA9800EFC859 /* Build configuration list for PBXProject "RCTDirectedScrollView" */ = {
258 | isa = XCConfigurationList;
259 | buildConfigurations = (
260 | 899B2D981DE4DA9800EFC859 /* Debug */,
261 | 899B2D991DE4DA9800EFC859 /* Release */,
262 | );
263 | defaultConfigurationIsVisible = 0;
264 | defaultConfigurationName = Release;
265 | };
266 | 899B2D9A1DE4DA9800EFC859 /* Build configuration list for PBXNativeTarget "RCTDirectedScrollView" */ = {
267 | isa = XCConfigurationList;
268 | buildConfigurations = (
269 | 899B2D9B1DE4DA9800EFC859 /* Debug */,
270 | 899B2D9C1DE4DA9800EFC859 /* Release */,
271 | );
272 | defaultConfigurationIsVisible = 0;
273 | defaultConfigurationName = Release;
274 | };
275 | /* End XCConfigurationList section */
276 | };
277 | rootObject = 899B2D891DE4DA9800EFC859 /* Project object */;
278 | }
279 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView/DirectedScrollViewChildManager.h:
--------------------------------------------------------------------------------
1 | //
2 | // DirectedScrollViewChildManager.h
3 | // DirectedScrollViewChildManager
4 | //
5 |
6 | #import
7 | #import
8 | #import
9 |
10 | @interface DirectedScrollViewChild : RCTView
11 |
12 | @property (nonatomic, strong) NSString *scrollDirection;
13 |
14 | - (BOOL)shouldScrollHorizontally;
15 |
16 | - (BOOL)shouldScrollVertically;
17 |
18 | @end
19 |
20 | @interface DirectedScrollViewChildManager : RCTViewManager
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView/DirectedScrollViewChildManager.m:
--------------------------------------------------------------------------------
1 | //
2 | // DirectedScrollViewChildManager.m
3 | // DirectedScrollViewChildManager
4 | //
5 |
6 | #import "DirectedScrollViewChildManager.h"
7 | #import
8 | #import
9 | #import
10 |
11 | @implementation DirectedScrollViewChild
12 |
13 | static NSString *const SCROLL_DIRECTION_BOTH = @"both";
14 | static NSString *const SCROLL_DIRECTION_HORIZONTAL = @"horizontal";
15 | static NSString *const SCROLL_DIRECTION_VERTICAL = @"vertical";
16 |
17 | - (BOOL)shouldScrollHorizontally {
18 | return [self.scrollDirection isEqualToString:SCROLL_DIRECTION_BOTH] ||
19 | [self.scrollDirection isEqualToString:SCROLL_DIRECTION_HORIZONTAL];
20 | }
21 |
22 | - (BOOL)shouldScrollVertically {
23 | return [self.scrollDirection isEqualToString:SCROLL_DIRECTION_BOTH] ||
24 | [self.scrollDirection isEqualToString:SCROLL_DIRECTION_VERTICAL];
25 | }
26 |
27 | @end
28 |
29 | @implementation DirectedScrollViewChildManager
30 |
31 | RCT_EXPORT_MODULE()
32 |
33 | @synthesize bridge = _bridge;
34 |
35 | - (UIView *)view
36 | {
37 | DirectedScrollViewChild *directedScrollViewChild = [[DirectedScrollViewChild alloc] init];
38 |
39 | directedScrollViewChild.pointerEvents = RCTPointerEventsBoxNone;
40 |
41 | return directedScrollViewChild;
42 | }
43 |
44 | RCT_EXPORT_VIEW_PROPERTY(scrollDirection, NSString)
45 |
46 | @end
47 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView/DirectedScrollViewManager.h:
--------------------------------------------------------------------------------
1 | //
2 | // DirectedScrollViewManager.h
3 | // DirectedScrollViewManager
4 | //
5 |
6 | #import
7 | #import
8 |
9 | @protocol DirectedScrollViewDelegate
10 |
11 | -(void)scrollViewWillBeginDragging;
12 | -(void)scrollViewDidEndDragging;
13 |
14 | @end
15 |
16 | @interface DirectedScrollViewManager : RCTViewManager
17 |
18 | @end
19 |
--------------------------------------------------------------------------------
/ios/RCTDirectedScrollView/DirectedScrollViewManager.m:
--------------------------------------------------------------------------------
1 | //
2 | // DirectedScrollViewManager.m
3 | // DirectedScrollViewManager
4 | //
5 |
6 | #import "DirectedScrollViewManager.h"
7 | #import "DirectedScrollViewChildManager.h"
8 | #import
9 | #import
10 | #import
11 |
12 | @interface DirectedScrollView : RCTScrollView
13 |
14 | @property (nonatomic, weak) id delegate;
15 |
16 | @end
17 |
18 | @implementation DirectedScrollView
19 |
20 | #pragma mark - ScrollView delegate
21 |
22 | - (void)scrollViewDidScroll:(UIScrollView *)scrollView
23 | {
24 | [super scrollViewDidScroll:scrollView];
25 | UIView *contentView = [self contentView];
26 |
27 | for (UIView *subview in contentView.reactSubviews)
28 | {
29 | DirectedScrollViewChild *scrollableChild = (DirectedScrollViewChild*)subview;
30 |
31 | if (subview == nil) continue;
32 |
33 | if (![scrollableChild shouldScrollVertically]) {
34 | CGFloat scrollTop = scrollView.contentOffset.y + self.contentInset.top;
35 |
36 | // adjust the y offset based on the current zoom scale
37 | // if we're zoomed in the offset required will be less, if we're zoomed out it will be more
38 | CGFloat yOffset = scrollTop / scrollView.zoomScale;
39 |
40 | // translate the horizontally scrolling subview by the calculated y offset
41 | // this cancels out the vertical translation applied by the scrollview and keeps the y position fixed
42 | scrollableChild.transform = CGAffineTransformMakeTranslation(0, yOffset);
43 | }
44 |
45 | if (![scrollableChild shouldScrollHorizontally]) {
46 | CGFloat scrollLeft = scrollView.contentOffset.x + self.contentInset.left;
47 |
48 | // adjust the x offset based on the current zoom scale
49 | // if we're zoomed in the offset required will be less, if we're zoomed out it will be more
50 | CGFloat xOffset = scrollLeft / scrollView.zoomScale;
51 |
52 | // translate the vertically scrolling subview by the calculated x offset
53 | // this cancels out the horizontal translation applied by the scrollview and keeps the x position fixed
54 | scrollableChild.transform = CGAffineTransformMakeTranslation(xOffset, 0);
55 | }
56 | }
57 | }
58 |
59 | - (void)scrollViewWillBeginDragging:(UIScrollView *)scrollView {
60 | [super scrollViewWillBeginDragging:scrollView];
61 | if ([self.delegate respondsToSelector:@selector(scrollViewWillBeginDragging)]) {
62 | [self.delegate scrollViewWillBeginDragging];
63 | }
64 | }
65 |
66 | -(void)scrollViewDidEndDragging:(UIScrollView *)scrollView willDecelerate:(BOOL)decelerate {
67 | [super scrollViewDidEndDragging:scrollView willDecelerate:decelerate];
68 | if ([self.delegate respondsToSelector:@selector(scrollViewDidEndDragging)]) {
69 | [self.delegate scrollViewDidEndDragging];
70 | }
71 | }
72 |
73 | @end
74 |
75 | @implementation DirectedScrollViewManager
76 |
77 | RCT_EXPORT_MODULE()
78 |
79 | @synthesize bridge = _bridge;
80 |
81 | - (UIView *)view
82 | {
83 | DirectedScrollView *directedScrollView = [[DirectedScrollView alloc] initWithEventDispatcher:self.bridge.eventDispatcher];
84 |
85 | directedScrollView.delegate = self;
86 |
87 | return directedScrollView;
88 | }
89 |
90 | // RCTDirectedScrollViewDelegate methods
91 |
92 | -(void)scrollViewWillBeginDragging {
93 | [self.bridge.eventDispatcher sendDeviceEventWithName:@"scrollViewWillBeginDragging" body:nil];
94 | }
95 |
96 | -(void)scrollViewDidEndDragging {
97 | [self.bridge.eventDispatcher sendDeviceEventWithName:@"scrollViewDidEndDragging" body:nil];
98 | }
99 |
100 |
101 | // RCTScrollView properties
102 |
103 | RCT_EXPORT_VIEW_PROPERTY(bounces, BOOL)
104 | RCT_EXPORT_VIEW_PROPERTY(alwaysBounceHorizontal, BOOL)
105 | RCT_EXPORT_VIEW_PROPERTY(alwaysBounceVertical, BOOL)
106 | RCT_EXPORT_VIEW_PROPERTY(bouncesZoom, BOOL)
107 | RCT_EXPORT_VIEW_PROPERTY(maximumZoomScale, CGFloat)
108 | RCT_EXPORT_VIEW_PROPERTY(minimumZoomScale, CGFloat)
109 | RCT_EXPORT_VIEW_PROPERTY(showsHorizontalScrollIndicator, BOOL)
110 | RCT_EXPORT_VIEW_PROPERTY(showsVerticalScrollIndicator, BOOL)
111 | RCT_EXPORT_VIEW_PROPERTY(canCancelContentTouches, BOOL)
112 | RCT_EXPORT_VIEW_PROPERTY(centerContent, BOOL)
113 | RCT_EXPORT_VIEW_PROPERTY(automaticallyAdjustContentInsets, BOOL)
114 | RCT_EXPORT_VIEW_PROPERTY(decelerationRate, CGFloat)
115 | RCT_EXPORT_VIEW_PROPERTY(directionalLockEnabled, BOOL)
116 | RCT_EXPORT_VIEW_PROPERTY(scrollEnabled, BOOL)
117 | RCT_REMAP_VIEW_PROPERTY(pinchGestureEnabled, scrollView.pinchGestureEnabled, BOOL)
118 | RCT_EXPORT_VIEW_PROPERTY(contentInset, UIEdgeInsets)
119 | RCT_EXPORT_VIEW_PROPERTY(scrollIndicatorInsets, UIEdgeInsets)
120 | RCT_EXPORT_VIEW_PROPERTY(snapToInterval, int)
121 | RCT_EXPORT_VIEW_PROPERTY(scrollEventThrottle, NSTimeInterval)
122 | RCT_EXPORT_VIEW_PROPERTY(snapToAlignment, NSString)
123 | RCT_EXPORT_VIEW_PROPERTY(onScrollBeginDrag, RCTDirectEventBlock)
124 | RCT_EXPORT_VIEW_PROPERTY(onScroll, RCTDirectEventBlock)
125 | RCT_EXPORT_VIEW_PROPERTY(onScrollEndDrag, RCTDirectEventBlock)
126 | RCT_EXPORT_VIEW_PROPERTY(onMomentumScrollBegin, RCTDirectEventBlock)
127 | RCT_EXPORT_VIEW_PROPERTY(onMomentumScrollEnd, RCTDirectEventBlock)
128 |
129 | // RCTScrollView methods
130 |
131 | RCT_EXPORT_METHOD(scrollTo:(nonnull NSNumber *)reactTag
132 | offsetX:(CGFloat)x
133 | offsetY:(CGFloat)y
134 | animated:(BOOL)animated)
135 | {
136 | [self.bridge.uiManager addUIBlock:
137 | ^(__unused RCTUIManager *uiManager, NSDictionary *viewRegistry){
138 | UIView *view = viewRegistry[reactTag];
139 | if ([view conformsToProtocol:@protocol(RCTScrollableProtocol)]) {
140 | [(id)view scrollToOffset:(CGPoint){x, y} animated:animated];
141 | } else {
142 | RCTLogError(@"tried to scrollTo: on non-RCTScrollableProtocol view %@ with tag #%@", view, reactTag);
143 | }
144 | }];
145 | }
146 |
147 | RCT_EXPORT_METHOD(zoomToStart:(nonnull NSNumber *)reactTag
148 | animated:(BOOL)animated)
149 | {
150 | [self.bridge.uiManager addUIBlock:
151 | ^(__unused RCTUIManager *uiManager, NSDictionary *viewRegistry){
152 | UIView *view = viewRegistry[reactTag];
153 | if ([view conformsToProtocol:@protocol(RCTScrollableProtocol)]) {
154 | [(id)view zoomToRect:CGRectMake(0, 0, 0, 0) animated:animated];
155 | [((RCTScrollView*)view).scrollView setZoomScale:1.0 animated:animated];
156 | } else {
157 | RCTLogError(@"tried to zoomToRect: on non-RCTScrollableProtocol view %@ with tag #%@", view, reactTag);
158 | }
159 | }];
160 | }
161 |
162 | @end
163 |
--------------------------------------------------------------------------------
/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "react-native-directed-scrollview",
3 | "version": "2.0.0",
4 | "description": "A natively implemented scrollview component which lets you specify different scroll directions for child content.",
5 | "main": "index.js",
6 | "scripts": {
7 | "test": ""
8 | },
9 | "repository": {
10 | "type": "git",
11 | "url": "git+https://github.com/chrisfisher/react-native-directed-scrollview.git"
12 | },
13 | "keywords": [
14 | "react-component",
15 | "react-native",
16 | "ios",
17 | "android",
18 | "scrollview",
19 | "horizontal",
20 | "vertical",
21 | "direction"
22 | ],
23 | "peerDependencies": {
24 | "react-native": ">=0.56.0"
25 | },
26 | "nativePackage": true,
27 | "rnpm": {
28 | "android": {
29 | "packageInstance": "new DirectedScrollViewPackage()"
30 | },
31 | "ios": {
32 | "project": "ios/RCTDirectedScrollView.xcodeproj"
33 | }
34 | },
35 | "author": "Chris Fisher",
36 | "license": "MIT",
37 | "bugs": {
38 | "url": "https://github.com/chrisfisher/react-native-directed-scrollview/issues"
39 | },
40 | "homepage": "https://github.com/chrisfisher/react-native-directed-scrollview#readme"
41 | }
42 |
--------------------------------------------------------------------------------
/react-native-directed-scrollview.podspec:
--------------------------------------------------------------------------------
1 | require 'json'
2 |
3 | package = JSON.parse(File.read(File.join(__dir__, 'package.json')))
4 |
5 | Pod::Spec.new do |s|
6 | s.name = package['name']
7 | s.version = package['version']
8 | s.summary = package['description']
9 | s.description = package['description']
10 | s.license = package['license']
11 | s.author = package['author']
12 | s.homepage = package['homepage']
13 | s.source = { :git => 'https://github.com/chrisfisher/react-native-directed-scrollview.git', :tag => s.version }
14 |
15 | s.requires_arc = true
16 | s.platform = :ios, '7.0'
17 |
18 | s.preserve_paths = 'README.md', 'package.json', 'index.js'
19 | s.source_files = 'ios/DirectedScrollView/*.{h,m}'
20 |
21 | s.dependency 'React'
22 | end
23 |
--------------------------------------------------------------------------------
/yarn.lock:
--------------------------------------------------------------------------------
1 | # THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY.
2 | # yarn lockfile v1
3 |
4 |
5 |
--------------------------------------------------------------------------------
|