File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -176,6 +176,8 @@ - (void)setPageWithoutAnimation:(NSInteger)index {
176
176
- (void )goTo : (NSInteger )index animated : (BOOL )animated {
177
177
NSInteger numberOfPages = _nativeChildrenViewControllers.count ;
178
178
179
+ _nativePageViewController.view .userInteractionEnabled = NO ;
180
+
179
181
_destinationIndex = index;
180
182
181
183
@@ -210,6 +212,7 @@ - (void)setPagerViewControllers:(NSInteger)index
210
212
int position = (int ) index;
211
213
strongEventEmitter.onPageSelected (RNCViewPagerEventEmitter::OnPageSelected{.position = static_cast <double >(position)});
212
214
strongSelf->_currentIndex = index;
215
+ strongSelf->_nativePageViewController .view .userInteractionEnabled = YES ;
213
216
}
214
217
}];
215
218
}
Original file line number Diff line number Diff line change @@ -178,6 +178,7 @@ - (void)setReactViewControllers:(NSInteger)index
178
178
179
179
if (finished) {
180
180
strongSelf.animating = NO ;
181
+ strongSelf.reactPageViewController .view .userInteractionEnabled = YES ;
181
182
}
182
183
183
184
if (strongSelf.eventDispatcher ) {
@@ -225,6 +226,8 @@ - (void)updateDataSource {
225
226
- (void )goTo : (NSInteger )index animated : (BOOL )animated {
226
227
NSInteger numberOfPages = self.reactSubviews .count ;
227
228
229
+ _reactPageViewController.view .userInteractionEnabled = NO ;
230
+
228
231
_destinationIndex = index;
229
232
230
233
if (numberOfPages == 0 || index < 0 || index > numberOfPages - 1 ) {
You can’t perform that action at this time.
0 commit comments