mirror of
https://codeberg.org/comaps/comaps
synced 2025-12-20 13:23:59 +00:00
[ios] Fix shift+scroll wheel zooming out
When you press shift on macOS, the normal scroll wheel action on a mouse is changed to horizontal scroll instead of vertical That meant this check never entered, and since translation.y = 0 you always zoom out Signed-off-by: eisa01 <eisa01@gmail.com>
This commit is contained in:
@@ -938,7 +938,7 @@ NSString *const kAboutSegue = @"Map2About";
|
|||||||
case UIGestureRecognizerStateChanged:
|
case UIGestureRecognizerStateChanged:
|
||||||
{
|
{
|
||||||
CGPoint translation = [recognizer translationInView:self.view];
|
CGPoint translation = [recognizer translationInView:self.view];
|
||||||
if (translation.x == 0 && CGPointEqualToPoint(translation, CGPointZero))
|
if (translation.y == 0)
|
||||||
return;
|
return;
|
||||||
self.userTouchesAction = UserTouchesActionScale;
|
self.userTouchesAction = UserTouchesActionScale;
|
||||||
static const CGFloat kScaleFactor = 0.9;
|
static const CGFloat kScaleFactor = 0.9;
|
||||||
|
|||||||
Reference in New Issue
Block a user