belongs to Maven artifact com.android.support:support-compat:28.0.0-alpha1
NotificationCompat.DecoratedCustomViewStyle
public
static
class
NotificationCompat.DecoratedCustomViewStyle
extends NotificationCompat.Style
java.lang.Object | ||
↳ | android.support.v4.app.NotificationCompat.Style | |
↳ | android.support.v4.app.NotificationCompat.DecoratedCustomViewStyle |
Notification style for custom views that are decorated by the system.
Instead of providing a notification that is completely custom, a developer can set this style and still obtain system decorations like the notification header with the expand affordance and actions.
Use setCustomContentView(RemoteViews)
,
setCustomBigContentView(RemoteViews)
and
setCustomHeadsUpContentView(RemoteViews)
to set the
corresponding custom views to display.
To use this style with your Notification, feed it to
setStyle(Style)
like so:
Notification noti = new NotificationCompat.Builder() .setSmallIcon(R.drawable.ic_stat_player) .setLargeIcon(albumArtBitmap)) .setCustomContentView(contentView) .setStyle(new NotificationCompat.DecoratedCustomViewStyle()) .build();
If you are using this style, consider using the corresponding styles like
TextAppearance_Compat_Notification
or
TextAppearance_Compat_Notification_Title
in
your custom views in order to get the correct styling on each platform version.
Summary
Public constructors | |
---|---|
NotificationCompat.DecoratedCustomViewStyle()
|
Inherited methods | |
---|---|
From
class
android.support.v4.app.NotificationCompat.Style
| |
From
class
java.lang.Object
|
Public constructors
NotificationCompat.DecoratedCustomViewStyle
NotificationCompat.DecoratedCustomViewStyle ()
Annotations
Interfaces
- ActionBarDrawerToggle.Delegate
- ActionBarDrawerToggle.DelegateProvider
- ActivityCompat.OnRequestPermissionsResultCallback
- ActivityCompat.PermissionCompatDelegate
- FragmentManager.BackStackEntry
- FragmentManager.OnBackStackChangedListener
- LoaderManager.LoaderCallbacks
- NotificationCompat.Action.Extender
- NotificationCompat.Extender
- SharedElementCallback.OnSharedElementsReadyListener
- TaskStackBuilder.SupportParentable
Classes
- ActionBarDrawerToggle
- ActivityCompat
- ActivityManagerCompat
- ActivityOptionsCompat
- AlarmManagerCompat
- AppLaunchChecker
- AppOpsManagerCompat
- BundleCompat
- DialogFragment
- Fragment
- Fragment.SavedState
- FragmentActivity
- FragmentContainer
- FragmentController
- FragmentHostCallback
- FragmentManager
- FragmentManager.FragmentLifecycleCallbacks
- FragmentManagerNonConfig
- FragmentPagerAdapter
- FragmentStatePagerAdapter
- FragmentTabHost
- FragmentTransaction
- FrameMetricsAggregator
- JobIntentService
- ListFragment
- LoaderManager
- NavUtils
- NotificationCompat
- NotificationCompat.Action
- NotificationCompat.Action.Builder
- NotificationCompat.Action.WearableExtender
- NotificationCompat.BigPictureStyle
- NotificationCompat.BigTextStyle
- NotificationCompat.Builder
- NotificationCompat.CarExtender
- NotificationCompat.CarExtender.UnreadConversation
- NotificationCompat.CarExtender.UnreadConversation.Builder
- NotificationCompat.DecoratedCustomViewStyle
- NotificationCompat.InboxStyle
- NotificationCompat.MessagingStyle
- NotificationCompat.MessagingStyle.Message
- NotificationCompat.Style
- NotificationCompat.WearableExtender
- NotificationCompatExtras
- NotificationCompatSideChannelService
- NotificationManagerCompat
- RemoteInput
- RemoteInput.Builder
- ServiceCompat
- ShareCompat
- ShareCompat.IntentBuilder
- ShareCompat.IntentReader
- SharedElementCallback
- TaskStackBuilder
Exceptions