diff options
author | Kirill Zhdanovich <kzhdanovich@gmail.com> | 2013-03-01 16:48:17 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:51:31 +0300 |
commit | 2f22518cdd180a29f474e23a8e0faac77012941e (patch) | |
tree | d9eb63ec77fe8f2197d8710163631b8c33ad7d5c /iphone | |
parent | c68e1b3ad3ffe2144150f0572536a28ffb1c5946 (diff) |
[iOS] Now recognisers work if user after scaling starts draging
Diffstat (limited to 'iphone')
-rw-r--r-- | iphone/Maps/Classes/MapViewController.mm | 21 |
1 files changed, 16 insertions, 5 deletions
diff --git a/iphone/Maps/Classes/MapViewController.mm b/iphone/Maps/Classes/MapViewController.mm index f5d2206965..2afd35afa2 100644 --- a/iphone/Maps/Classes/MapViewController.mm +++ b/iphone/Maps/Classes/MapViewController.mm @@ -593,16 +593,27 @@ { if (recognizer.state == UIGestureRecognizerStateChanged) { - if (startedScaling) - { - f.StopScale(ScaleEvent(p1.x, p1.y, p2.x, p2.y)); - startedScaling = NO; - } + if (startedScaling) + { + f.StopScale(ScaleEvent(p1.x, p1.y, p2.x, p2.y)); + CGPoint z = [self pointFromRecognizerWithScaleFactor:recognizer]; + f.StartDrag(DragEvent(z.x, z.y)); + startedScaling = NO; + lastRotateTime = 0; + } + else + { + [self handlePan:(UIPanGestureRecognizer *)recognizer]; + } } if (recognizer.state != UIGestureRecognizerStateEnded) { return; } + else if (!startedScaling) + { + [self handlePan:(UIPanGestureRecognizer *)recognizer]; + } } //Work of Scale Recognizer |