g-app-intents.jd revision f54574a90cb2c09af7fb5518e3e859726ce75027
1page.title=Intents List: Invoking Google Applications on Android Devices
2@jd:body
3
4<div class="sidebox-wrapper">
5<div class="sidebox">
6For more information about intents, see the <a
7href="{@docRoot}guide/topics/intents/intents-filters.html">Intents and Intent Filters</a>.
8</div>
9</div>
10
11<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>
12
13<p>Note that this list is not comprehensive.</p>
14
15  <table>
16      <tr>
17          <th scope="col">Target Application</th>
18          <th scope="col">Intent URI</th>
19          <th scope="col">Intent Action</th>
20          <th scope="col">Result</th>
21      </tr>
22      <tr>
23          <td rowspan="2">Browser</td>
24          <td>http://<em>web_address</em><br />
25              https://<em>web_address</em></td>
26          <td>VIEW</td>
27          <td>Open a browser window to the URL specified. </td>
28      </tr>
29      <tr>
30          <td>&quot;&quot; (empty string) <br />
31          http://<em>web_address</em><br />
32          https://<em>web_address</em></td>
33          <td>WEB_SEARCH</td>
34          <td>Opens the file at the location on the device in the browser. </td>
35      </tr>
36      <tr>
37          <td rowspan="2">Dialer</td>
38          <td height="103">tel: <em>phone_number</em></td>
39          <td>CALL</td>
40          <td><p>Calls the entered phone number. Valid telephone numbers as defined
41              in <a href="http://tools.ietf.org/html/rfc3966">the IETF RFC 3966</a> are
42              accepted. Valid examples include the following:</p>
43              <ul>
44                  <li>tel:2125551212 </li>
45                  <li>tel:
46                      (212) 555 1212</li>
47              </ul>
48              <p>The dialer is good at normalizing some kinds of schemes: for example
49                  telephone numbers, so the schema described isn't strictly required
50                  in the {@link android.net.Uri#parse(java.lang.String)
51                  Uri(URI string)} factory. However, if you have not tried a
52                  schema or are unsure whether it can be handled, use the {@link
53                  android.net.Uri#fromParts(java.lang.String, java.lang.String,
54                  java.lang.String) Uri.fromParts(scheme, ssp, fragment)} factory
55              instead.</p>
56              <p><strong><em>Note:</em></strong>&nbsp;&nbsp;&nbsp;This requires your
57              application to request the following permission in your manifest: <code>&lt;uses-permission
58              id=&quot;android.permission.CALL_PHONE&quot; /&gt;</code></p></td>
59      </tr>
60      <tr>
61          <td><p>tel:<em>phone_number</em><br />
62          voicemail:</p>          </td>
63          <td>DIAL</td>
64          <td><p>Dials (but does not actually initiate the call) the number given
65                  (or the stored voicemail on the phone). Telephone number normalization
66                  described for CALL applies to DIAL as well. </p>              </td>
67      </tr>
68      <tr>
69          <td>Google Maps</td>
70          <td>geo:<em>latitude</em>,<em>longitude</em><br />
71              geo:<em>latitude</em>,<em>longitude</em>?z=<em>zoom</em><br />
72              geo:0,0?q=<em>my+street+address</em><br />
73              geo:0,0?q=<em>business+near+city</em><br />
74          </td>
75          <td>VIEW</td>
76          <td>Opens the Maps application to the given location or query. The Geo URI scheme
77              (not fully supported) is <a href="http://tools.ietf.org/html/draft-mayrhofer-geo-uri-00">currently under
78              development</a>.<p>
79              The <em>z</em> field specifies the zoom level. A zoom level of 1 shows the whole Earth, centered at the
80              given <em>lat</em>,<em>lng</em>. A zoom level of 2 shows a quarter of the Earth, and so on. The highest
81              zoom level is 23. A larger zoom level will be clamped to 23.
82          </td>
83      </tr>
84      <tr>
85          <td>Google Streetview</td>          
86<td>google.streetview:cbll=<em>lat</em>,<em>lng</em>&amp;cbp=1,<em>yaw</em>,,<em>pitch</em>,<em>zoom</em>&amp;mz=<em>mapZoom</em>
87          </td>
88          <td>VIEW</td>
89          <td>Opens the Street View application to the given location. The URI scheme is
90            based on the syntax used for Street View panorama information in Google Maps URLs.<p>
91            The cbll field is required. The cbp and mz fields are optional.<p>
92     <table border:none>
93       <tr><td><em>lat</em></td><td>latitude</td></tr>
94       <tr><td><em>lng</em></td><td>longitude</td></tr>
95       <tr><td><em>yaw</em></td><td>Panorama center-of-view in degrees clockwise from North.<br />
96       <b>Note:</b> The two commas after the yaw parameter are required. They are present
97       for backwards-compatibility reasons.</td></tr>
98       <tr><td><em>pitch</em></td><td>Panorama center-of-view in degrees from
99           -90 (look straight up) to 90 (look straight down.)</td></tr>
100       <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 />
101       A zoom of 1.0 is 90 degree horizontal FOV for a nominal landscape mode 4
102x 3 aspect ratio display Android phones in portrait mode will adjust the zoom so
103that the vertical FOV is approximately the same as the landscape vertical FOV.
104This means that the horizontal FOV of an Android phone in portrait mode is much
105narrower than in landscape mode. This is done to minimize the fisheye lens
106effect that would be present if a 90 degree horizontal FOV was used in portrait
107mode.</td></tr>
108       <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
109       Maps activity when the Street View "Go to Maps" menu item is chosen. It corresponds to the <em>z</em> parameter in
110       the geo: intent.</td></tr>
111       </table>
112          </td>
113      </tr>
114  </table>
115  <p></p>
116