Map iOS touches to Flutter view coordinate system (flutter/engine#4425)
This change ensures that touches are mapped to the Flutter view co-ordinate system. In the case of a Flutter view that doesn't share the same origin and orientation as the screen co-ordinate system, touches were appled in the wrong location. This bug affected Flutter views whose origin was not the screen origin and Flutter apps running with the in-call status bar on iPhones other than the iPhone X.
This commit is contained in:
@@ -483,7 +483,7 @@ static inline blink::PointerData::DeviceKind DeviceKindFromTouchType(UITouch* to
|
||||
}
|
||||
|
||||
FXL_DCHECK(device_id != 0);
|
||||
CGPoint windowCoordinates = [touch locationInView:nil];
|
||||
CGPoint windowCoordinates = [touch locationInView:self.view];
|
||||
|
||||
blink::PointerData pointer_data;
|
||||
pointer_data.Clear();
|
||||
|
||||
Reference in New Issue
Block a user