Recent Support Library Revisions

Revision 28.0.0 Production

(September 21, 2018)

This is the stable release of Support Library 28.0.0 and is suitable for use
in production. This will be the last feature release under the
android.support packaging, and developers are encouraged to
migrate to AndroidX.

New features

Revision 28.0.0 RC 2

(August 27, 2018)

This release candidate of the support library is considered feature-complete and
its public API surface is stable. This release will be shipped as final stable
version barring any critical issues that may arise. This release should be safe
to use in production. Please report any issues to the
public issue
tracker.

Fixed issues

`Fragment.getViewLifecycleOwner()` does not get stopped when hitting the home
button (public issue
113070421)
([public issue 113070421](https://issuetracker.google.com/issues/113070421))

Revision 28.0.0 RC 1

(August 6, 2018)

This release candidate of the support library is considered feature-complete and
its public API surface is stable. This release will be shipped as final stable
version barring any critical issues that may arise. This release should be safe
to use in production. Please report any issues to the
public issue
tracker.

Note: Some libraries, such as media2, have remained in alpha stage as their API
surfaces are not yet finalized. We do not recommend using alpha libraries in
production. Libraries should strictly avoid depending on alpha libraries in
production, as their API surfaces may change in source- and binary-incompatible
ways.

Fixed issues

BottomNavigationView menu is not initialized correctly in design support library

ConcurrentModificationException in RecyclerView selection library when data
set changed with removing selection

PreferenceThemeOverlay has been updated to the latest material theme. If no
custom theme is provided, PreferenceThemeOverlay is used as the default
theme.

PreferenceThemeOverlay.v14 and PreferenceThemeOverlay.v14.Material themes have
been deprecated in favour of PreferenceThemeOverlay.

PreferenceGroup visibility is now tied to its children - hiding a parent group
will also prevent its children from being shown in the hierarchy. Use
Preference.isShown() to get whether a Preference is actually displayed to the
user in the hierarchy.

Preference.onSetInitialValue(boolean, Object) has been deprecated and replaced
with onSetInitialValue(Object). PreferenceDataStore now also correctly
restores default values.

Revision 28.0.0 Beta 1

(July 2018)

This beta release of the Support Library is considered feature-complete and
its public API surface is stable, barring any critical issues that may arise.
While this release is safe to use in production, it may still contain bugs.
Please report any issues to the public issue
tracker.

Fixed issues

GestureSelectionHelper eating events on non-selectable items

Slider slices can have duplicated thumb icon when slider value is being updated

Revision 28.0.0 Alpha 1

(March 2018)

Note: 28.0.0-alpha1 is a pre-release version to support the Android P
developer preview. Its API surface is subject to change, and it does not
necessarily include features or bug fixes from the latest stable versions of
Support Library. For details on the P developer preview, see the
release notes.

Important changes

As previously noted in the
Android KTX announcement, we are continuing to adopt the
androidx package prefix across our libraries. A selection of
brand-new libraries, including heifwriter and
recyclerview-selection, are starting out in this new package. We
hope the division between android.* and androidx.*
makes it more obvious which APIs are bundled with the platform, and which are
static libraries for app developers that work across different versions of
Android.

We have split parts of support-core-ui, support-core-utils, and
support-compat into smaller libraries. This change will help us detangle support
library dependencies in the future. We now have the following new libraries:

Mouse-driven band selection allows users to a select block of items in a
RecyclerView list using traditional mouse pointer band/lasso actions.

Support for touch-centric devices, including phone and touch-enabled laptop
form-factors, as well as pointer-centric devices.

HEIF Writer provides support for writing HEIF-format still images.

Design Library

We’ve introduced a new application theme,
Theme.MaterialComponents, with new attributes and updated styles
for components.

We’ve added the following components:

BottomAppBar

Chip

ChipGroup

MaterialButton

MaterialCardView

Slices provides a framework for apps to embed templated content from
other apps.

slices-builders contains methods to build content in a template format.

slices-view contain methods to present that content.

Browser actions provides a protocol for app developers to launch a
consistent (but customizable) context menu for URLs. This feature is dependent
on the presence of a browser app (such as Chrome, where this feature is still
under development) that implements support for browser actions.

Revision 27.1.0 Release

(February 2018)

Important Changes

The underlying implementation of Loaders has been rewritten to use Lifecycle. While the API
remains unchanged, there are a number of behavior changes:

initLoader(), restartLoader(), and
destroyLoader() can now only be called on the main thread.

A Loader's onStartLoading() and onStopLoading() are
now called when the containing FragmentActivity/Fragment is started and stopped,
respectively.

onLoadFinished() will only be called between onStart()
and onStop. As a result, Fragment transactions can now safely be done in
onLoadFinished().

The FragmentController methods related to Loaders are now
deprecated.

DialogFragment’s getDialog() will now be
non-null up until onDestroyView(), instead of becoming null in
dismiss(). You can now determine if the Dialog was manually
dismissed in onStop() by checking if
getDialog().isShowing() returns false.

New APIs

ListAdapter
for RecyclerView (along with AsyncListDiffer) make it easier to compute list diffs on a
background thread. These can help your RecyclerView animate content changes
automatically, with minimal work on the UI thread. They use DiffUtil under the hood.

SortedList.ReplaceAll enables updating all data in a
SortedList, which runs all appropriate animations for inserts, removals,
changes, and moves (moves are treated as removals and inserts).

Fragments now have
requireContext(), requireActivity(),
requireHost(), and requireFragmentManager()
methods, which return a NonNull object of the equivalent get
methods or throw an
IllegalStateException.

requireViewById(), a @NonNull compat version
of findViewById() has been added to WindowCompat,
ActivityCompat, and ViewCompat,
which throw an IllegalArgumentException when the target cannot be
found.

LoaderCallbacks
methods now have the appropriate @Nullable and
@NonNull annotations.

Fragment can use support library versions of
Transition for fragment transitions, including shared-element
transitions.

Content paging library (android.support.content.ContentPager)
provides support for paging content exposed via a ContentProvider. Use of this library allows a client to
avoid expensive interprocess "cursor window swaps" on the UI thread,
providing a compatibility library for the Android 8.0 feature.

ViewCompat now adds wrappers for autofill methods, including
getImportantForAutofill(),
isImportantForAutofill(), setAutofillHints(), and
setImportantForAutofill().

Leanback
gets new features and polish, and loses some deprecated classes, such as:

Some deprecated classes removed as we move away from old pre-V14 APIs,
such as android.support.v7.NotificationCompat (use v4 NotificationCompat instead),
KeyEventCompat, ParallelExecutorCompat, and
SearchViewCompat.

Revision 26.0.0 Release

(July 2017)

Important: The support libraries are now available
through Google's Maven repository. You do not need to download the support
repository from the SDK Manager. For more information, see
Support Library Setup.

Important changes

The minimum SDK version has been increased to 14. As a result, many APIs
that existed only for compatibility with pre-14 API levels have been
deprecated. Clients of these APIs should migrate to their framework
equivalents as noted in the reference page for each deprecated API.

The Wear UI Library contains classes that help you implement
patterns and layouts that work on Wear devices. For more information,
see
Using the Wear UI Library.

New APIs

New fastScrollEnabled boolean flag for RecyclerView. If enabled,
fastScrollHorizontalThumbDrawable,
fastScrollHorizontalTrackDrawable,
fastScrollVerticalThumbDrawable, and
fastScrollVerticalTrackDrawable must be set.