src/video/uikit/SDL_uikitview.m
changeset 12201 8bdc4d340419
parent 11846 a1b2d62d5d73
child 12404 eb60e952b13f
     1.1 --- a/src/video/uikit/SDL_uikitview.m	Sat Aug 18 17:23:40 2018 -0400
     1.2 +++ b/src/video/uikit/SDL_uikitview.m	Mon Sep 24 11:49:25 2018 -0700
     1.3 @@ -252,34 +252,34 @@
     1.4  
     1.5  - (void)pressesBegan:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event
     1.6  {
     1.7 -	if (!SDL_AppleTVRemoteOpenedAsJoystick) {
     1.8 -    	for (UIPress *press in presses) {
     1.9 -        	SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.10 -        	SDL_SendKeyboardKey(SDL_PRESSED, scancode);
    1.11 -    	}
    1.12 -	}
    1.13 +    if (!SDL_AppleTVRemoteOpenedAsJoystick) {
    1.14 +        for (UIPress *press in presses) {
    1.15 +            SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.16 +            SDL_SendKeyboardKey(SDL_PRESSED, scancode);
    1.17 +        }
    1.18 +    }
    1.19      [super pressesBegan:presses withEvent:event];
    1.20  }
    1.21  
    1.22  - (void)pressesEnded:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event
    1.23  {
    1.24 -	if (!SDL_AppleTVRemoteOpenedAsJoystick) {
    1.25 -		for (UIPress *press in presses) {
    1.26 -			SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.27 -			SDL_SendKeyboardKey(SDL_RELEASED, scancode);
    1.28 -		}
    1.29 -	}
    1.30 +    if (!SDL_AppleTVRemoteOpenedAsJoystick) {
    1.31 +        for (UIPress *press in presses) {
    1.32 +            SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.33 +            SDL_SendKeyboardKey(SDL_RELEASED, scancode);
    1.34 +        }
    1.35 +    }
    1.36      [super pressesEnded:presses withEvent:event];
    1.37  }
    1.38  
    1.39  - (void)pressesCancelled:(NSSet<UIPress *> *)presses withEvent:(UIPressesEvent *)event
    1.40  {
    1.41 -	if (!SDL_AppleTVRemoteOpenedAsJoystick) {
    1.42 -		for (UIPress *press in presses) {
    1.43 -			SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.44 -			SDL_SendKeyboardKey(SDL_RELEASED, scancode);
    1.45 -		}
    1.46 -	}
    1.47 +    if (!SDL_AppleTVRemoteOpenedAsJoystick) {
    1.48 +        for (UIPress *press in presses) {
    1.49 +            SDL_Scancode scancode = [self scancodeFromPressType:press.type];
    1.50 +            SDL_SendKeyboardKey(SDL_RELEASED, scancode);
    1.51 +        }
    1.52 +    }
    1.53      [super pressesCancelled:presses withEvent:event];
    1.54  }
    1.55