Merge "docs: Release Notes v2 for Android 4.0.3, ADT 16.0.1, Support lib r5-r6" into ics-mr1

This commit is contained in:
Joe Fernandez
2011-12-15 23:11:26 -08:00
committed by Android (Google) Code Review
2 changed files with 72 additions and 62 deletions

View File

@@ -4,7 +4,7 @@ page.title=Support Package
<div id="qv-wrapper"> <div id="qv-wrapper">
<div id="qv"> <div id="qv">
<h2>In this document</h2> <h2>In this document</h2>
<ol> <ol>
<li><a href="#Notes">Revisions</a></li> <li><a href="#Notes">Revisions</a></li>
@@ -35,7 +35,8 @@ worry less about platform versions.</p>
<p class="note"><strong>Note:</strong> The Support Package includes more than one support <p class="note"><strong>Note:</strong> The Support Package includes more than one support
library. Each one has a different <em>minimum API level</em>. For example, one library requires API library. Each one has a different <em>minimum API level</em>. For example, one library requires API
level 4 or higher, while another requires API level 13 or higher (v13 is a superset of v4 and includes additional level 4 or higher, while another requires API level 13 or higher (v13 is a superset of v4 and
includes additional
support classes to work with v13 APIs). The minimum version is indicated support classes to work with v13 APIs). The minimum version is indicated
by the directory name, such as {@code v4/} and {@code v13/}.</p> by the directory name, such as {@code v4/} and {@code v13/}.</p>
@@ -54,7 +55,9 @@ the Support Package, as denoted by revision number.</p>
</a></p> </a></p>
<div class="toggle-content-toggleme" style="padding-left:2em"> <div class="toggle-content-toggleme" style="padding-left:2em">
<dl> <p class="note"><strong>Note:</strong> Reference for support library APIs are now available with
the framework references, for example: {@link android.support.v4.app}.</p>
<dl>
<dt>Changes for v4 support library:</dt> <dt>Changes for v4 support library:</dt>
<dd> <dd>
<ul> <ul>
@@ -68,22 +71,22 @@ the Support Package, as denoted by revision number.</p>
<li>Added {@link android.support.v4.view.PagerTitleStrip}, a non-interactive title <li>Added {@link android.support.v4.view.PagerTitleStrip}, a non-interactive title
strip, that can be added as a child of ViewPager. Developers can supply text strip, that can be added as a child of ViewPager. Developers can supply text
appearance and color, as well as layout sizing and gravity information.</li> appearance and color, as well as layout sizing and gravity information.</li>
<li>Updated PagerAdapter methods to take ViewGroup objects, rather than View to avoid <li>Updated {@link android.support.v4.view.PagerAdapter} methods to take ViewGroup
class casting in adapter implementations. For more information, see objects, rather than View to avoid class casting in adapter implementations.</li>
{@link android.support.v4.view.PagerAdapter}.</li> <li>Updated {@link android.support.v4.view.ViewPager} to use Launcher-style
<li>Updated ViewPager to use Launcher Workspace-style fling behavior.</li> fling behavior.</li>
<li>Bug fixes for user interface interaction and test automation.</li> <li>Bug fixes for user interface interaction and test automation.</li>
</ul> </ul>
</li> </li>
<li>Support for Fragments: <li>Support for Fragments:
<ul> <ul>
<li>Changed {@code setStartDeferred()} method to {@link <li>Changed {@code setStartDeferred()} method to {@link
android.support.v4.app.Fragment#setUserVisibleHint}.</li> android.support.v4.app.Fragment#setUserVisibleHint}.</li>
<li>Added deferred start for off-screen pages to improve performance.</li> <li>Added deferred start for off-screen pages to improve performance.</li>
</ul> </ul>
</li> </li>
<li>Support for Accessiblity APIs: <li>Support for Accessiblity APIs:
<ul> <ul>
<li>Updated {@link android.support.v4.view.AccessibilityDelegateCompat} methods <li>Updated {@link android.support.v4.view.AccessibilityDelegateCompat} methods
@@ -91,7 +94,7 @@ the Support Package, as denoted by revision number.</p>
<li>Added new APIs needed by the v4 samples.</li> <li>Added new APIs needed by the v4 samples.</li>
</ul> </ul>
</li> </li>
</ul> </ul>
</dd> </dd>
</dl> </dl>
@@ -111,34 +114,35 @@ the Support Package, as denoted by revision number.</p>
<ul> <ul>
<li>Support for Accessiblity APIs: <li>Support for Accessiblity APIs:
<ul> <ul>
<li>Added <code>AccessibilityDelegateCompat</code> to support <li>Added {@link android.support.v4.view.AccessibilityDelegateCompat}
{@link android.view.View.AccessibilityDelegate}.</li> to support {@link android.view.View.AccessibilityDelegate}.</li>
<li>Added <code>AccessibilityEventCompat</code> to support <li>Added {@link android.support.v4.view.accessibility.AccessibilityEventCompat}
{@link android.view.accessibility.AccessibilityEvent}.</li> to support {@link android.view.accessibility.AccessibilityEvent}.</li>
<li>Added <code>AccessibilityManagerCompat</code> to support <li>Added {@link android.support.v4.view.accessibility.AccessibilityManagerCompat}
{@link android.view.accessibility.AccessibilityManager}.</li> to support {@link android.view.accessibility.AccessibilityManager}.</li>
<li>Added <code>AccessibilityNodeInfoCompat</code> to support <li>Added {@link android.support.v4.view.accessibility.AccessibilityNodeInfoCompat}
{@link android.view.accessibility.AccessibilityNodeInfo}.</li> to support {@link android.view.accessibility.AccessibilityNodeInfo}.</li>
<li>Added <code>AccessibilityRecordCompat</code> to support <li>Added {@link android.support.v4.view.accessibility.AccessibilityRecordCompat}
{@link android.view.accessibility.AccessibilityRecord}.</li> to support {@link android.view.accessibility.AccessibilityRecord}.</li>
<li>Added <code>AccessibilityServiceInfoCompat</code> to support <li>Added {@link
{@link android.accessibilityservice.AccessibilityServiceInfo}.</li> android.support.v4.accessibilityservice.AccessibilityServiceInfoCompat}
to support {@link android.accessibilityservice.AccessibilityServiceInfo}.</li>
<li>Added <code>ViewGroupCompat</code> <li>Added {@link android.support.v4.view.ViewGroupCompat}
to support accessibility features in {@link android.view.ViewGroup}. to support accessibility features in {@link android.view.ViewGroup}.
</li> </li>
<li>Modified <code>ViewCompat</code> <li>Modified {@link android.support.v4.view.ViewCompat}
to support accessibility features in {@link android.view.View}.</li> to support accessibility features in {@link android.view.View}.</li>
</ul> </ul>
</li> </li>
<li>Changes to <code>ViewPager</code>: <li>Changes to ViewPager:
<ul> <ul>
<li>Added support for margins between pages. <li>Added support for margins between pages.
An optional {@link android.graphics.drawable.Drawable} can be provided An optional {@link android.graphics.drawable.Drawable} can be provided
@@ -170,7 +174,7 @@ the Support Package, as denoted by revision number.</p>
<ul> <ul>
<li>Added <code>EdgeEffectCompat</code> to <li>Added <code>EdgeEffectCompat</code> to
support {@link android.widget.EdgeEffect}.</li> support {@link android.widget.EdgeEffect}.</li>
<li>Added <code>LocalBroadcastManager</code> to allow applications to easily <li>Added <code>LocalBroadcastManager</code> to allow applications to easily
register for and receive intents within a single application without register for and receive intents within a single application without
broadcasting them globally.</li> broadcasting them globally.</li>
@@ -186,7 +190,7 @@ the Support Package, as denoted by revision number.</p>
<li>Various bug fixes.</li> <li>Various bug fixes.</li>
</ul> </ul>
</li> </li>
<li>Fixed a {@link android.content.Loader} bug that caused issues in <li>Fixed a {@link android.content.Loader} bug that caused issues in
canceling {@link android.os.AsyncTask}s when running on Froyo and older canceling {@link android.os.AsyncTask}s when running on Froyo and older
versions of the platform. The support versions of the platform. The support
@@ -210,7 +214,7 @@ the Support Package, as denoted by revision number.</p>
Compatibility Package, revision 3 (July 2011) Compatibility Package, revision 3 (July 2011)
</a></p> </a></p>
<div class="toggle-content-toggleme" style="padding-left:2em"> <div class="toggle-content-toggleme" style="padding-left:2em">
<dl> <dl>
<dt>Changes for v4 support library:</dt> <dt>Changes for v4 support library:</dt>
<dd> <dd>
@@ -264,7 +268,7 @@ Android 3.2 and higher (all other APIs in the v4 library are already available w
Compatibility Package, revision 2 (May 2011) Compatibility Package, revision 2 (May 2011)
</a></p> </a></p>
<div class="toggle-content-toggleme" style="padding-left:2em"> <div class="toggle-content-toggleme" style="padding-left:2em">
<dl> <dl>
<dt>Changes for v4 library:</dt> <dt>Changes for v4 library:</dt>
<dd> <dd>
@@ -287,7 +291,7 @@ Android 3.2 and higher (all other APIs in the v4 library are already available w
Compatibility Package, revision 1 (March 2011) Compatibility Package, revision 1 (March 2011)
</a></p> </a></p>
<div class="toggle-content-toggleme" style="padding-left:2em"> <div class="toggle-content-toggleme" style="padding-left:2em">
<p>Initial release with the v4 library.</p> <p>Initial release with the v4 library.</p>
</div> </div>
@@ -301,7 +305,7 @@ Android 3.2 and higher (all other APIs in the v4 library are already available w
Manager. To install:</p> Manager. To install:</p>
<ol> <ol>
<li>Launch the SDK and AVD Manager. <li>Launch the SDK and AVD Manager.
<p>From Eclipse, you can select <strong>Window</strong> <p>From Eclipse, you can select <strong>Window</strong>
&gt; <strong>Android SDK and AVD Manager</strong>. Or, launch {@code SDK Manager.exe} from &gt; <strong>Android SDK and AVD Manager</strong>. Or, launch {@code SDK Manager.exe} from
the {@code &lt;sdk&gt;/} directory (on Windows only) or {@code android} from the {@code the {@code &lt;sdk&gt;/} directory (on Windows only) or {@code android} from the {@code
@@ -328,7 +332,7 @@ libs/} directory.
<p>For example, the library that supports API level 4 and up is located at {@code <p>For example, the library that supports API level 4 and up is located at {@code
&lt;sdk&gt;/extras/android/support/v4/android-support-v4.jar}.</p> &lt;sdk&gt;/extras/android/support/v4/android-support-v4.jar}.</p>
</li> </li>
<li>Add the JAR to your project build path. <li>Add the JAR to your project build path.
<p>In Eclipse, right-click the JAR file in the Package Explorer, select <strong>Build <p>In Eclipse, right-click the JAR file in the Package Explorer, select <strong>Build
Path</strong> &gt; <strong>Add to Build Path</strong>.</p> Path</strong> &gt; <strong>Add to Build Path</strong>.</p>
</li> </li>
@@ -339,7 +343,7 @@ provided APIs are available in the {@code android.support} package (for
example, {@code android.support.v4}).</p> example, {@code android.support.v4}).</p>
<p class="note"><strong>Tip:</strong> To see the library APIs in action, take a look at the sample <p class="note"><strong>Tip:</strong> To see the library APIs in action, take a look at the sample
apps in {@code extras/android/support/&lt;version&gt;/samples/}.</p> apps in {@code &lt;sdk&gt;/extras/android/support/&lt;version&gt;/samples/}.</p>
<p class="warning"><strong>Warning:</strong> Be certain that you not confuse the standard <p class="warning"><strong>Warning:</strong> Be certain that you not confuse the standard
{@code android} packages with those in {@code android.support} library. Some code completion tools {@code android} packages with those in {@code android.support} library. Some code completion tools
@@ -377,17 +381,20 @@ differences, however. Most notably:</p>
<ul> <ul>
<li>When creating an activity to use fragments, you must declare your activity to extend the <li>When creating an activity to use fragments, you must declare your activity to extend the
{@code FragmentActivity} class (instead of the traditional {@link android.app.Activity} {@link android.support.v4.app.FragmentActivity} class (instead of the traditional
class).</li> {@link android.app.Activity} class).</li>
<li>To manage your fragments and loaders, you must use the methods {@code <li>To manage your fragments and loaders, you must use the methods
FragmentActivity.getSupportFragmentManager()} and {@code {@link android.support.v4.app.FragmentActivity#getSupportFragmentManager
FragmentActivity.getSupportLoaderManager()} (instead of the {@link FragmentActivity.getSupportFragmentManager()} and
android.app.Activity#getFragmentManager()} and {@link android.app.Activity#getLoaderManager()} {@link android.support.v4.app.FragmentActivity#getSupportLoaderManager
methods).</li> FragmentActivity.getSupportLoaderManager()} (instead of the
{@link android.app.Activity#getFragmentManager()} and
{@link android.app.Activity#getLoaderManager()} methods).</li>
<li>The {@link android.app.ActionBar} is <strong>not supported</strong> by the library. <li>The {@link android.app.ActionBar} is <strong>not supported</strong> by the library.
However, when creating your <a href="{@docRoot}guide/topics/ui/menus.html#options-menu">Options However, when creating your <a href="{@docRoot}guide/topics/ui/menus.html#options-menu">Options
Menu</a>, you can declare which items should be added to the Action Bar when it's available (on Menu</a>, you can declare which items should be added to the Action Bar when it's available (on
Android 3.0 or later). You can do so with the {@code MenuCompat.setShowAsAction()} method. For Android 3.0 or later). You can do so with the
{@link android.support.v4.view.MenuCompat#setShowAsAction MenuCompat.setShowAsAction()} method, for
example: example:
<pre> <pre>
public boolean onCreateOptionsMenu(Menu menu) { public boolean onCreateOptionsMenu(Menu menu) {
@@ -397,16 +404,19 @@ public boolean onCreateOptionsMenu(Menu menu) {
return true; return true;
} }
</pre> </pre>
<p>Also see the <a href="{@docRoot}resources/samples/ActionBarCompat/index.html">Action Bar
Compatibility</a> sample for a demonstration of how to use {@link android.app.ActionBar} on Android
3.0+ and also support action bar functionality on older versions.</p>
</li> </li>
</ul> </ul>
<div class="note"><p><strong>Tip:</strong> To enable the Holographic theme on devices <div class="note"><p><strong>Tip:</strong> To enable the Holographic theme on devices
running Android 3.0 or higher, declare in your manifest file that your application targets running Android 3.0 or higher, declare in your manifest file that your application targets
API level 11. For example:</p> API level 11, for example:</p>
<pre> <pre>
&lt;uses-sdk android:minSdkVersion="4" android:targetSdkVersion="11" /&gt; &lt;uses-sdk android:minSdkVersion="4" android:targetSdkVersion="11" /&gt;
</pre> </pre>
<p>This way, your application automatically receives the Holographic theme and the Action Bar for <p>This way, your application automatically receives the Holographic theme and the Action Bar for
each activity when running on Android 3.0 and higher.</p> each activity when running on Android 3.0 and higher.</p>
</div> </div>
@@ -417,29 +427,29 @@ Apps for Android 3.0</a>.</p>
<h2 id="Docs">Reference Docs</h2> <h2 id="Docs">Reference Docs</h2>
<p>The libraries currently do not provide reference documentation for the included APIs. To generate <p>The reference documentation for the Support Packages is included as part of the Android
your own set using the {@code javadoc} tool, perform the following from a command (as appropriate online developer documentation:</p>
for the library version you're using). In this example, documentation is generated for the v4
library:</p>
<pre class="no-pretty-print"> <ul>
cd &lt;sdk&gt;/extras/android/support/v4/ <li><a href="{@docRoot}reference/android/support/v4/app/package-summary.html">Support Package
mkdir docs API 4 Reference</a></li>
javadoc -sourcepath src/java/ -subpackages android.support.v4 -d docs <li><a href="{@docRoot}reference/android/support/v13/app/package-summary.html">Support Package
</pre> API 13 Reference</a></li>
<p>Open the {@code docs/index.html} file to begin browsing the generated documentation.</p> </ul>
<h2 id="Samples">Samples</h2> <h2 id="Samples">Samples</h2>
<p>If you want to see some code that uses the support libraries, samples are included with the <p>If you want to see some code that uses the support libraries, samples are included with the
Support Package, inside each support library directory. For example, at {@code Support Package, inside each support library directory, for example; {@code
extras/android/support/v4/samples/}.</p> &lt;sdk&gt;/extras/android/support/v4/samples/}. You can also view these samples as part of the
Android online developer documentation:</p>
<ul>
<li><a href="{@docRoot}resources/samples/Support4Demos/index.html">Support API 4 Demos</a></li>
<li><a href="{@docRoot}resources/samples/Support13Demos/index.html">Support API 13 Demos</a></li>
</ul>
<p>Additionally, the <a href="http://code.google.com/p/iosched/">Google I/O App</a> is a complete <p>Additionally, the <a href="http://code.google.com/p/iosched/">Google I/O App</a> is a complete
application that uses the v4 support library to provide a single APK for both handsets and tablets application that uses the v4 support library to provide a single APK for both handsets and tablets
and also demonstrates some of Android's best practices in Android UI design.</p> and also demonstrates some of Android's best practices in Android UI design.</p>

View File

@@ -94,7 +94,7 @@ padding: .25em 1em;
<ul> <ul>
<li>Added Lint tools to detect common errors in Android projects. <li>Added Lint tools to detect common errors in Android projects.
(<a href="http://tools.android.com/recent/lint">more info</a>)</li> (<a href="http://tools.android.com/recent/lint">more info</a>)</li>
<a>Added sensor emulation support, which allows the emulator to read sensor data from a <li>Added sensor emulation support, which allows the emulator to read sensor data from a
physical Android device. physical Android device.
(<a href="http://tools.android.com/recent/sensoremulation">more info</a>)</li> (<a href="http://tools.android.com/recent/sensoremulation">more info</a>)</li>
<li>Added support for using a webcam to emulate a camera on Mac OS X.</li> <li>Added support for using a webcam to emulate a camera on Mac OS X.</li>
@@ -201,7 +201,7 @@ padding: .25em 1em;
commands, see the commands, see the
<a href="{@docRoot}guide/developing/building/building-cmdline.html#AntReference">Ant Command <a href="{@docRoot}guide/developing/building/building-cmdline.html#AntReference">Ant Command
Reference</a>.</li> Reference</a>.</li>
<li>Changed how library projects are built.</a></li> <li>Changed how library projects are built.</li>
<li>Improved incremental builds, so that resource compilation runs less frequently. Builds no <li>Improved incremental builds, so that resource compilation runs less frequently. Builds no
longer run when you edit strings or layouts (unless you add a new <code>id</code>) and no longer longer run when you edit strings or layouts (unless you add a new <code>id</code>) and no longer
run once for each library project.</li> run once for each library project.</li>