gpt4 book ai didi

ios - Mapkit 标注附件按钮激活

转载 作者:行者123 更新时间:2023-11-29 05:36:09 26 4
gpt4 key购买 nike

我正在使用 MapKit 来显示带有许多注释的 map 。每个注释都有一个带有 UIButton 的标注。大多数情况下一切都工作正常,但只要 UIButton 后面有注释,就不可能激活它。我希望 UIButton 可以激活,无论背景注释如何。有没有办法忽略标注后面的注释?

最佳答案

我找到了解决此问题的适当方法:

(void)mapView:(MKMapView *)mapView didSelectAnnotationView:(MKAnnotationView *)view {
[view.superview bringSubviewToFront:view];
}

https://github.com/danielbarela/ios-map-callout-test/issues/1

关于ios - Mapkit 标注附件按钮激活,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/57017307/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com