单击公开指示器按钮后如何转到第二个视图控制器 [英] How to go to second view controller after click on disclosure indicator button

查看:19
本文介绍了单击公开指示器按钮后如何转到第二个视图控制器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想从地图视图中删除现有的注释.Scenerio 是单击现有的注释标注部分(披露指示器按钮),它将引导用户到另一个视图控制器并显示一个按钮,您可以删除选定的注释.实际上,我正在努力创建完全相同的谷歌地图应用程序,这是我现在正在努力的部分.任何帮助,将不胜感激!

I would like to remove existing annotation from mapview. Scenerio is to click on existing annotation callout part (disclosureindicator button) and it would lead user to another viewcontroller and shows a button you could remove the selected annotation. Actually, I am working on to create exactly same google map application, that is part I am struggling now. Any help would be appreciated!

推荐答案

MKMapView 类有两种添加/删除注解的方法:

The MKMapView class has two methods you need to add/remove annotations:

addAnnotation: id <MKAnnotation>
removeAnnotation: id <MKAnnotation>

您将创建一个实现 MKAnnotation 协议的类.这是另一个 SO 问题中的示例:MKAnnotation,简单示例

You'd create a class that implements the protocol MKAnnotation. Here's an example in another SO question: MKAnnotation, simple example

这篇关于单击公开指示器按钮后如何转到第二个视图控制器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆