116 lines
5.9 KiB
Plaintext
116 lines
5.9 KiB
Plaintext
|
page.title=Intents List: Invoking Google Applications on Android Devices
|
||
|
@jd:body
|
||
|
|
||
|
<div class="sidebox-wrapper">
|
||
|
<div class="sidebox">
|
||
|
For more information about intents, see the <a
|
||
|
href="{@docRoot}guide/topics/intents/intents-filters.html">Intents and Intent Filters</a>.
|
||
|
</div>
|
||
|
</div>
|
||
|
|
||
|
<p>The table below lists the intents that your application can send, to invoke Google applications on Android devices in certain ways. For each action/uri pair, the table describes how the receiving Google application handles the intent. </p>
|
||
|
|
||
|
<p>Note that this list is not comprehensive.</p>
|
||
|
|
||
|
<table>
|
||
|
<tr>
|
||
|
<th scope="col">Target Application</th>
|
||
|
<th scope="col">Intent URI</th>
|
||
|
<th scope="col">Intent Action</th>
|
||
|
<th scope="col">Result</th>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td rowspan="2">Browser</td>
|
||
|
<td>http://<em>web_address</em><br />
|
||
|
https://<em>web_address</em></td>
|
||
|
<td>VIEW</td>
|
||
|
<td>Open a browser window to the URL specified. </td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td>"" (empty string) <br />
|
||
|
http://<em>web_address</em><br />
|
||
|
https://<em>web_address</em></td>
|
||
|
<td>WEB_SEARCH</td>
|
||
|
<td>Opens the file at the location on the device in the browser. </td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td rowspan="2">Dialer</td>
|
||
|
<td height="103">tel: <em>phone_number</em></td>
|
||
|
<td>CALL</td>
|
||
|
<td><p>Calls the entered phone number. Valid telephone numbers as defined
|
||
|
in <a href="http://tools.ietf.org/html/rfc3966">the IETF RFC 3966</a> are
|
||
|
accepted. Valid examples include the following:</p>
|
||
|
<ul>
|
||
|
<li>tel:2125551212 </li>
|
||
|
<li>tel:
|
||
|
(212) 555 1212</li>
|
||
|
</ul>
|
||
|
<p>The dialer is good at normalizing some kinds of schemes: for example
|
||
|
telephone numbers, so the schema described isn't strictly required
|
||
|
in the {@link android.net.Uri#parse(java.lang.String)
|
||
|
Uri(URI string)} factory. However, if you have not tried a
|
||
|
schema or are unsure whether it can be handled, use the {@link
|
||
|
android.net.Uri#fromParts(java.lang.String, java.lang.String,
|
||
|
java.lang.String) Uri.fromParts(scheme, ssp, fragment)} factory
|
||
|
instead.</p>
|
||
|
<p><strong><em>Note:</em></strong> This requires your
|
||
|
application to request the following permission in your manifest: <code><uses-permission
|
||
|
id="android.permission.CALL_PHONE" /></code></p></td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td><p>tel:<em>phone_number</em><br />
|
||
|
voicemail:</p> </td>
|
||
|
<td>DIAL</td>
|
||
|
<td><p>Dials (but does not actually initiate the call) the number given
|
||
|
(or the stored voicemail on the phone). Telephone number normalization
|
||
|
described for CALL applies to DIAL as well. </p> </td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td>Google Maps</td>
|
||
|
<td>geo:<em>latitude</em>,<em>longitude</em><br />
|
||
|
geo:<em>latitude</em>,<em>longitude</em>?z=<em>zoom</em><br />
|
||
|
geo:0,0?q=<em>my+street+address</em><br />
|
||
|
geo:0,0?q=<em>business+near+city</em><br />
|
||
|
</td>
|
||
|
<td>VIEW</td>
|
||
|
<td>Opens the Maps application to the given location or query. The Geo URI scheme
|
||
|
(not fully supported) is <a href="http://tools.ietf.org/html/draft-mayrhofer-geo-uri-00">currently under
|
||
|
development</a>.<p>
|
||
|
The <em>z</em> field specifies the zoom level. A zoom level of 1 shows the whole Earth, centered at the
|
||
|
given <em>lat</em>,<em>lng</em>. A zoom level of 2 shows a quarter of the Earth, and so on. The highest
|
||
|
zoom level is 23. A larger zoom level will be clamped to 23.
|
||
|
</td>
|
||
|
</tr>
|
||
|
<tr>
|
||
|
<td>Google Streetview</td>
|
||
|
<td>google.streetview:cbll=<em>lat</em>,<em>lng</em>&cbp=1,<em>yaw</em>,,<em>pitch</em>,<em>zoom</em>&mz=<em>mapZoom</em>
|
||
|
</td>
|
||
|
<td>VIEW</td>
|
||
|
<td>Opens the Street View application to the given location. The URI scheme is
|
||
|
based on the syntax used for Street View panorama information in Google Maps URLs.<p>
|
||
|
The cbll field is required. The cbp and mz fields are optional.<p>
|
||
|
<table border:none>
|
||
|
<tr><td><em>lat</em></td><td>latitude</td></tr>
|
||
|
<tr><td><em>lng</em></td><td>longitude</td></tr>
|
||
|
<tr><td><em>yaw</em></td><td>Panorama center-of-view in degrees clockwise from North.<br />
|
||
|
<b>Note:</b> The two commas after the yaw parameter are required. They are present
|
||
|
for backwards-compatibility reasons.</td></tr>
|
||
|
<tr><td><em>pitch</em></td><td>Panorama center-of-view in degrees from
|
||
|
-90 (look straight up) to 90 (look straight down.)</td></tr>
|
||
|
<tr><td><em>zoom</em></td><td>Panorama zoom. 1.0 = normal zoom, 2.0 = zoomed in 2x, 3.0 = zoomed in 4x, and so on.<br />
|
||
|
A zoom of 1.0 is 90 degree horizontal FOV for a nominal landscape mode 4
|
||
|
x 3 aspect ratio display Android phones in portrait mode will adjust the zoom so
|
||
|
that the vertical FOV is approximately the same as the landscape vertical FOV.
|
||
|
This means that the horizontal FOV of an Android phone in portrait mode is much
|
||
|
narrower than in landscape mode. This is done to minimize the fisheye lens
|
||
|
effect that would be present if a 90 degree horizontal FOV was used in portrait
|
||
|
mode.</td></tr>
|
||
|
<tr><td><em>mapZoom</em></td><td>The map zoom of the map location associated with this panorama. This value is passed on to the
|
||
|
Maps activity when the Street View "Go to Maps" menu item is chosen. It corresponds to the <em>z</em> parameter in
|
||
|
the geo: intent.</td></tr>
|
||
|
</table>
|
||
|
</td>
|
||
|
</tr>
|
||
|
</table>
|
||
|
<p></p>
|