blob: 4d6262edb501ddcfe262c1f020e957758e04b405 [file] [log] [blame]
page.title=What's New
page.image=images/cards/samples-new_2x.png
@jd:body
<p>The following code samples were recently published. You can
download them in the Android SDK Manager under the <b>Samples for SDK</b>
component for Android 7.1 (API 25).</p>
<p class="note">
<strong>Note:</strong> The downloadable projects are designed
for use with Gradle and Android Studio.
</p>
<!-- NOTE TO EDITORS: add most recent samples first -->
<h3 id="app-shortcuts">App shortcuts sample</h3>
<!-- TBA
<img src="sample-img.png" style="float: left; padding-right: 0.5em"
width="xxx"/>
-->
<p>
This sample demonstrates how to use the <a href=
"/preview/app-shortcuts.html">app shortcuts API</a> introduced in Android 7.1
(API level 25). This API allows an application to define a set of intents
which are displayed when a user long-presses on the app's launcher icon.
Examples are given for registering links both statically in XML, as well as
dynamically at runtime.
</p>
<p>
<a href="/samples/AppShortcuts/index.html">App shortcuts sample</a>
</p>
<h3 id="img-kbd-app">Image keyboard app sample</h3>
<!-- TBA
<img src="sample-img.png" style="float: left; padding-right: 0.5em"
width="xxx"/>
-->
<p>
This sample demonstrates how to implement the <a href=
"/reference/android/view/inputmethod/InputConnection.html#commitContent(android.view.inputmethod.InputContentInfo,%20int,%20android.os.Bundle)">
Commit Content API</a>, using the <a href=
"/topic/libraries/support-library/index.html">Android Support Library</a>.
This API provides a universal way for IMEs to send images and other rich
content directly to a text editor in an app, allowing users to compose
content using custom emojis, stickers, or other rich content provided by
other applications.
</p>
<p>
<a href="/samples/CommitContentSampleApp/index.html">Image keyboard app sample</a>
</p>
<h3 id="img-kbd-ime">Image keyboard IME sample</h3>
<!-- TBA
<img src="sample-img.png" style="float: left; padding-right: 0.5em"
width="xxx"/>
-->
<p>
This sample demonstrates how to write a <a href=
"/preview/image-keyboard.html">custom image keyboard</a> using the <a href=
"/reference/android/view/inputmethod/InputConnection.html#commitContent(android.view.inputmethod.InputContentInfo,%20int,%20android.os.Bundle)">
Commit Content API</a> and the <a href=
"/topic/libraries/support-library/index.html">Android Support Library</a>.
This keyboard will be displayed inside compatible apps (also using the Commit
Content API), allowing users to insert emojis, stickers, or other rich
content into text editors.
</p>
<p>
<a href="/samples/CommitContentSampleIME/index.html">Image keyboard IME sample</a>
</p>