简体   繁体   English

如何将自己的应用程序添加到地图应用程序列表中?

[英]How to add own application to the list of Maps Applications?

If some other application wants to show something on the map (uses link geo:lat,lng ), then before showing the map, it shows 'Maps Applications' list.如果其他应用程序想要在 map 上显示某些内容(使用链接geo:lat,lng ),那么在显示 map 之前,它会显示“地图应用程序”列表。 So, I could choose which map application should be started.所以,我可以选择应该启动哪个 map 应用程序。

How can I add my own application to this list?如何将我自己的应用程序添加到此列表中?

The list here shows the various URL formats used to launch Google apps (including maps).此处的列表显示了用于启动 Google 应用程序(包括地图)的各种 URL 格式。 To launch maps you would use:要启动地图,您将使用:

try {
    Intent myIntent = new Intent(android.content.Intent.ACTION_VIEW,       
        Uri.parse("geo:0.00,0.00"));
    startActivity(myIntent);
} catch (URISyntaxException e) { }

If you want the user to be presented with the option to open your app instead of Google Maps, then you have to register to handle the same Intent in your manifest, maybe something along the lines of this .如果您希望向用户显示打开您的应用程序而不是 Google 地图的选项,那么您必须注册以处理清单中的相同 Intent,可能类似于this

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 如何将您的应用程序添加到 Google 地图中的“共享此地点”列表 - How to add your application to the "share this place" list in Google maps 如何从谷歌播放获取我自己的应用程序列表列表 - How to get list of my own application list from google play Android谷歌地图添加到标记自己的标记 - Android google maps add to marker own tag 如何在带有图标的已安装Android应用程序列表中添加“多项选择”? - How to add a “multiple choice” in list of installed android applications with icons? 如何在aosp中更改源代码并在其上添加我们自己的应用程序 - How to change source code in aosp and add our own application on it 如何在自己的应用程序中创建和添加贴纸和笑脸 - How to Create and Add Stickers and Smiley's In You Own Application 如何在自己的过程中向具有库的Android应用程序添加分析 - How to add analytics to an Android application with a library in its own process 如何将自己的服务添加到BLE应用程序? - How do I add my own service to a BLE application? 如何创建我自己的指纹谷歌地图嵌入Android应用程序供公众使用 - how to create my own fingerprint for google maps embeded android application for public use 如何在两个自己的应用程序之间发送字符串? - How to send a string between two own applications?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM