當前位置: 首頁>>代碼示例>>Java>>正文


Java NotificationBuilderWithBuilderAccessor類代碼示例

本文整理匯總了Java中android.support.v4.app.NotificationBuilderWithBuilderAccessor的典型用法代碼示例。如果您正苦於以下問題:Java NotificationBuilderWithBuilderAccessor類的具體用法?Java NotificationBuilderWithBuilderAccessor怎麽用?Java NotificationBuilderWithBuilderAccessor使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


NotificationBuilderWithBuilderAccessor類屬於android.support.v4.app包,在下文中一共展示了NotificationBuilderWithBuilderAccessor類的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: addMediaStyleToBuilderLollipop

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
private static void addMediaStyleToBuilderLollipop(NotificationBuilderWithBuilderAccessor notificationbuilderwithbuilderaccessor, android.support.v4.app.Style style)
{
    if (style instanceof MediaStyle)
    {
        style = (MediaStyle)style;
        int ai[] = ((MediaStyle) (style)).mActionsToShowInCompact;
        if (((MediaStyle) (style)).mToken != null)
        {
            style = ((android.support.v4.app.Style) (((MediaStyle) (style)).mToken.getToken()));
        } else
        {
            style = null;
        }
        NotificationCompatImpl21.addMediaStyle(notificationbuilderwithbuilderaccessor, ai, style);
    }
}
 
開發者ID:Hamz-a,項目名稱:MyCTFWriteUps,代碼行數:17,代碼來源:NotificationCompat.java

示例2: addMediaStyle

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public static void addMediaStyle(NotificationBuilderWithBuilderAccessor b, int[] actionsToShowInCompact, Object token) {
    MediaStyle style = new MediaStyle(b.getBuilder());
    if (actionsToShowInCompact != null) {
        style.setShowActionsInCompactView(actionsToShowInCompact);
    }
    if (token != null) {
        style.setMediaSession((Token) token);
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:10,代碼來源:NotificationCompatImpl21.java

示例3: build

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public Notification build(android.support.v4.app.Builder builder, NotificationBuilderWithBuilderAccessor notificationbuilderwithbuilderaccessor)
{
    NotificationCompat.addMediaStyleToBuilderIcs(notificationbuilderwithbuilderaccessor, builder);
    notificationbuilderwithbuilderaccessor = notificationbuilderwithbuilderaccessor.build();
    NotificationCompat.addBigMediaStyleToBuilderJellybean(notificationbuilderwithbuilderaccessor, builder);
    return notificationbuilderwithbuilderaccessor;
}
 
開發者ID:Hamz-a,項目名稱:MyCTFWriteUps,代碼行數:8,代碼來源:NotificationCompat.java

示例4: addMediaStyleToBuilderIcs

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
private static void addMediaStyleToBuilderIcs(NotificationBuilderWithBuilderAccessor notificationbuilderwithbuilderaccessor, android.support.v4.app.Builder builder)
{
    if (builder.mStyle instanceof MediaStyle)
    {
        MediaStyle mediastyle = (MediaStyle)builder.mStyle;
        NotificationCompatImplBase.overrideContentView(notificationbuilderwithbuilderaccessor, builder.mContext, builder.mContentTitle, builder.mContentText, builder.mContentInfo, builder.mNumber, builder.mLargeIcon, builder.mSubText, builder.mUseChronometer, builder.mNotification.when, builder.mActions, mediastyle.mActionsToShowInCompact, mediastyle.mShowCancelButton, mediastyle.mCancelButtonIntent);
    }
}
 
開發者ID:Hamz-a,項目名稱:MyCTFWriteUps,代碼行數:9,代碼來源:NotificationCompat.java

示例5: addMediaStyle

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public static void addMediaStyle(NotificationBuilderWithBuilderAccessor notificationbuilderwithbuilderaccessor, int ai[], Object obj)
{
    notificationbuilderwithbuilderaccessor = new android.app.Notification.MediaStyle(notificationbuilderwithbuilderaccessor.getBuilder());
    if (ai != null)
    {
        notificationbuilderwithbuilderaccessor.setShowActionsInCompactView(ai);
    }
    if (obj != null)
    {
        notificationbuilderwithbuilderaccessor.setMediaSession((android.media.session.MediaSession.Token)obj);
    }
}
 
開發者ID:Hamz-a,項目名稱:MyCTFWriteUps,代碼行數:13,代碼來源:NotificationCompatImpl21.java

示例6: overrideContentView

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public static void overrideContentView(NotificationBuilderWithBuilderAccessor notificationbuilderwithbuilderaccessor, Context context, CharSequence charsequence, CharSequence charsequence1, CharSequence charsequence2, int i, Bitmap bitmap, CharSequence charsequence3, 
        boolean flag, long l, List list, int ai[], boolean flag1, PendingIntent pendingintent)
{
    context = generateContentView(context, charsequence, charsequence1, charsequence2, i, bitmap, charsequence3, flag, l, list, ai, flag1, pendingintent);
    notificationbuilderwithbuilderaccessor.getBuilder().setContent(context);
    if (flag1)
    {
        notificationbuilderwithbuilderaccessor.getBuilder().setOngoing(true);
    }
}
 
開發者ID:Hamz-a,項目名稱:MyCTFWriteUps,代碼行數:11,代碼來源:NotificationCompatImplBase.java

示例7: build

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public Notification build(android.support.v4.app.NotificationCompat.Builder b, NotificationBuilderWithBuilderAccessor builder) {
    NotificationCompat.addMediaStyleToBuilderIcs(builder, b);
    return builder.build();
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:5,代碼來源:NotificationCompat.java

示例8: addMediaStyleToBuilderLollipop

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
private static void addMediaStyleToBuilderLollipop(NotificationBuilderWithBuilderAccessor builder, Style style) {
    if (style instanceof MediaStyle) {
        MediaStyle mediaStyle = (MediaStyle) style;
        NotificationCompatImpl21.addMediaStyle(builder, mediaStyle.mActionsToShowInCompact, mediaStyle.mToken != null ? mediaStyle.mToken.getToken() : null);
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:7,代碼來源:NotificationCompat.java

示例9: addMediaStyleToBuilderIcs

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
private static void addMediaStyleToBuilderIcs(NotificationBuilderWithBuilderAccessor builder, android.support.v4.app.NotificationCompat.Builder b) {
    if (b.mStyle instanceof MediaStyle) {
        MediaStyle mediaStyle = b.mStyle;
        NotificationCompatImplBase.overrideContentView(builder, b.mContext, b.mContentTitle, b.mContentText, b.mContentInfo, b.mNumber, b.mLargeIcon, b.mSubText, b.mUseChronometer, b.mNotification.when, b.mActions, mediaStyle.mActionsToShowInCompact, mediaStyle.mShowCancelButton, mediaStyle.mCancelButtonIntent);
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:7,代碼來源:NotificationCompat.java

示例10: overrideContentView

import android.support.v4.app.NotificationBuilderWithBuilderAccessor; //導入依賴的package包/類
public static <T extends Action> void overrideContentView(NotificationBuilderWithBuilderAccessor builder, Context context, CharSequence contentTitle, CharSequence contentText, CharSequence contentInfo, int number, Bitmap largeIcon, CharSequence subText, boolean useChronometer, long when, List<T> actions, int[] actionsToShowInCompact, boolean showCancelButton, PendingIntent cancelButtonIntent) {
    builder.getBuilder().setContent(generateContentView(context, contentTitle, contentText, contentInfo, number, largeIcon, subText, useChronometer, when, actions, actionsToShowInCompact, showCancelButton, cancelButtonIntent));
    if (showCancelButton) {
        builder.getBuilder().setOngoing(true);
    }
}
 
開發者ID:JackChan1999,項目名稱:boohee_v5.6,代碼行數:7,代碼來源:NotificationCompatImplBase.java


注:本文中的android.support.v4.app.NotificationBuilderWithBuilderAccessor類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。