Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Call out issue #4

Open
pramodsharma403 opened this issue Sep 12, 2015 · 6 comments
Open

Call out issue #4

pramodsharma403 opened this issue Sep 12, 2015 · 6 comments

Comments

@pramodsharma403
Copy link

When two pins on same location or nearby then tap on location. You will see two callout popup. one of them never disappear after tapping on popup.
screen shot 2015-09-12 at 9 48 02 am

@myusuf08
Copy link

myusuf08 commented Oct 8, 2015

how to solve this?

@godara
Copy link

godara commented Oct 23, 2015

facing the same issue, any solution?

@mikeCalvir
Copy link

Did either of you solve this in the end? The problem we have is that because we aren't ever really selecting an annotation now showing an MKAnnotationView, we miss all of the default behaviour like automatically deselecting and hiding the views when the user taps away for example.

I have solved this by using notifications and having the views hide themselves when other views become active and when the map moves etc.

@fpena
Copy link

fpena commented Nov 9, 2016

The way I solved this:

Every time a new callout is shown, I hide every other callout. That way, only one is shown every time inside a map.

@rlogical-techsoft
Copy link

rlogical-techsoft commented Jul 26, 2017

@fpena Can you share me that files which you have changed for solve that issue Or let me know when i have to change in files?
Thanks

@fpena
Copy link

fpena commented Aug 4, 2017

@rlogical-techsoft I have implemented touchesBegan.

Something like this:

override func touchesBegan(touches: Set<UITouch>, withEvent event: UIEvent?) {
        if let touch = touches.first {
            for temp in self.mapView.annotations {
                if let view = self.mapView.viewForAnnotation(temp) {
                    let cast = view as? RHDXAnnotationView
                    if cast != nil {
                        cast!.hideCalloutView()
                    }
                }
            }
        }
    }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants