|
@@ -91,10 +91,10 @@ void _uikit_keyboard_init() ;
|
|
|
CGPoint locationInView = [self touchLocation:touch shouldNormalize:NO];
|
|
|
|
|
|
/* send moved event */
|
|
|
- SDL_SendMouseMotion(NULL, SDL_TOUCH_MOUSEID, 0, locationInView.x, locationInView.y);
|
|
|
+ SDL_SendMouseMotion(self->viewcontroller.window, SDL_TOUCH_MOUSEID, 0, locationInView.x, locationInView.y);
|
|
|
|
|
|
/* send mouse down event */
|
|
|
- SDL_SendMouseButton(NULL, SDL_TOUCH_MOUSEID, SDL_PRESSED, SDL_BUTTON_LEFT);
|
|
|
+ SDL_SendMouseButton(self->viewcontroller.window, SDL_TOUCH_MOUSEID, SDL_PRESSED, SDL_BUTTON_LEFT);
|
|
|
|
|
|
leftFingerDown = touch;
|
|
|
}
|
|
@@ -130,7 +130,7 @@ void _uikit_keyboard_init() ;
|
|
|
while(touch) {
|
|
|
if (touch == leftFingerDown) {
|
|
|
/* send mouse up */
|
|
|
- SDL_SendMouseButton(NULL, SDL_TOUCH_MOUSEID, SDL_RELEASED, SDL_BUTTON_LEFT);
|
|
|
+ SDL_SendMouseButton(self->viewcontroller.window, SDL_TOUCH_MOUSEID, SDL_RELEASED, SDL_BUTTON_LEFT);
|
|
|
leftFingerDown = nil;
|
|
|
}
|
|
|
|
|
@@ -173,7 +173,7 @@ void _uikit_keyboard_init() ;
|
|
|
CGPoint locationInView = [self touchLocation:touch shouldNormalize:NO];
|
|
|
|
|
|
/* send moved event */
|
|
|
- SDL_SendMouseMotion(NULL, SDL_TOUCH_MOUSEID, 0, locationInView.x, locationInView.y);
|
|
|
+ SDL_SendMouseMotion(self->viewcontroller.window, SDL_TOUCH_MOUSEID, 0, locationInView.x, locationInView.y);
|
|
|
}
|
|
|
|
|
|
CGPoint locationInView = [self touchLocation:touch shouldNormalize:YES];
|