blob: b3836f844904640869dcdcfe9913c8f558218d75 [file] [log] [blame]
Joe Fernandez306f1ce2015-05-01 12:51:21 -07001page.title=Samples
2
3@jd:body
4
5<p>
6 The following code samples are provided for the M Developer Preview. You can download them in the
7 Android SDK Manager under the <b>SDK Samples</b> component for the M Developer Preview.
8</p>
9
10<p class="note">
11 <strong>Note:</strong> These downloadable projects are designed
12 for use with Gradle and Android Studio.
13</p>
14
15
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070016<h3 id="RuntimePermissions">Runtime Permissions</h3>
Joe Fernandez306f1ce2015-05-01 12:51:21 -070017
18<p>
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070019 Android M changes the way system permissions work. Users are asked to approve permission
20 requests at runtime instead of during installation. This sample shows how to request these
21 permissions.
Joe Fernandez306f1ce2015-05-01 12:51:21 -070022</p>
23
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070024<p><a href="https://github.com/googlesamples/android-RuntimePermissions">Get it on GitHub</a></p>
Joe Fernandez306f1ce2015-05-01 12:51:21 -070025
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070026<h3 id="RuntimePermissionsCompat">Runtime Permissions Compat</h3>
Joe Fernandez306f1ce2015-05-01 12:51:21 -070027
28<p>
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070029 To support devices on previous versions of Android, this sample demonstrates how to work with the
30 new permissions system introduced in Android M by using a support library.
Joe Fernandez306f1ce2015-05-01 12:51:21 -070031</p>
32
Joe Fernandeza06ac3a2015-05-15 15:42:17 -070033<p><a href="https://github.com/googlesamples/android-RuntimePermissionsCompat">Get it on
34GitHub</a></p>
35
36<h3 id="VoiceCamera">Voice Camera</h3>
37
38<p>
39 This sample demonstrates how to implement the "OK Google, take a selfie" voice command and confirm
40 the user intent with the <code>VoiceInteraction</code> API.
41</p>
42
43<p><a href="https://github.com/googlesamples/android-VoiceCamera">Get it on GitHub</a></p>
44
45
46<h3 id="DeepLinkSharing">Deep Link Sharing</h3>
47
48<p>
49 This sample shows how to handle content shared via deep links in your app. It demonstrates how to
50 implement the <code>ChooserTargetService</code>.
51</p>
52
53<p><a href="https://github.com/googlesamples/android-DeepLinkSharing">Get it on GitHub</a></p>
54
55<h3 id="NotificationBuilder">Notification Builder</h3>
56
57<p>
58 This sample demonstrates the improved
59 <a href="{@docRoot}reference/android/app/Notification.html"><code>Notification</code></a>
60 memory footprint and simplified creation of notifications with custom views.
61</p>
62
63<p><a href="https://github.com/googlesamples/android-NotificationBuilder">Get it on GitHub</a></p>
64
65<h3 id="ActiveNotification">Active Notification</h3>
66
67<p>
68 This sample demonstrates how the
69 <a href="{@docRoot}reference/android/app/NotificationManager.html"><code>NotificationManager</code></a>
70 can tell you how many notifications your app is currently showing.
71</p>
72
73<p><a href="https://github.com/googlesamples/android-ActiveNotification">Get it on GitHub</a></p>
74
75<h3 id="VoiceSynthesizer">Voice Synthesizer</h3>
76
77<p>
78 This sample demonstrates how to use the <code>NativeAudio</code> APIs to demonstrate low-latency
79 audio processing.
80</p>
81
82<p><a href="https://github.com/googlesamples/android-VoiceSynthesizer">Get it on GitHub</a></p>
Joe Fernandez306f1ce2015-05-01 12:51:21 -070083
84