Skip to content

Commit

Permalink
Fix podspec test
Browse files Browse the repository at this point in the history
Summary:
Travis-CI
Closes #15428

Differential Revision: D5592214

Pulled By: javache

fbshipit-source-id: f006976d7183d845201c001be51d1546c9c31c5a
  • Loading branch information
javache authored and facebook-github-bot committed Aug 9, 2017
1 parent f06d992 commit 39eb6c5
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions React/Base/RCTTVRemoteHandler.m
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,9 @@
#import "RCTView.h"
#import "UIView+React.h"

#if __has_include("RCTDevMenu.h")
#import "RCTDevMenu.h"
#endif

@implementation RCTTVRemoteHandler {
NSMutableArray<UIGestureRecognizer *> *_tvRemoteGestureRecognizers;
Expand Down Expand Up @@ -62,13 +64,13 @@ - (instancetype)init
// Right
[self addTapGestureRecognizerWithSelector:@selector(swipedRight:)
pressType:UIPressTypeRightArrow];

// Recognizers for long button presses
// We don't intercept long menu press -- that's used by the system to go to the home screen

[self addLongPressGestureRecognizerWithSelector:@selector(longPlayPausePressed:)
pressType:UIPressTypePlayPause];

[self addLongPressGestureRecognizerWithSelector:@selector(longSelectPressed:)
pressType:UIPressTypeSelect];

Expand Down Expand Up @@ -114,8 +116,8 @@ - (void)longPlayPausePressed:(UIGestureRecognizer *)r
{
[self sendAppleTVEvent:@"longPlayPause" toView:r.view];

#if __has_include("RCTDevMenu.h") && RCT_DEV
// If shake to show is enabled on device, use long play/pause event to show dev menu
#if RCT_DEV
[[NSNotificationCenter defaultCenter] postNotificationName:RCTShowDevMenuNotification object:nil];
#endif
}
Expand Down Expand Up @@ -151,7 +153,7 @@ - (void)addLongPressGestureRecognizerWithSelector:(nonnull SEL)selector pressTyp
{
UILongPressGestureRecognizer *recognizer = [[UILongPressGestureRecognizer alloc] initWithTarget:self action:selector];
recognizer.allowedPressTypes = @[@(pressType)];

[_tvRemoteGestureRecognizers addObject:recognizer];
}

Expand Down

0 comments on commit 39eb6c5

Please sign in to comment.