語言

PictureInPictureParams.Builder.SetOverlayActions 方法

定義

設定覆蓋層動作和主要覆蓋層動作。

[Android.Runtime.Register("setOverlayActions", "(Ljava/util/List;Landroid/app/RemoteAction;)Landroid/app/PictureInPictureParams$Builder;", "GetSetOverlayActions_Ljava_util_List_Landroid_app_RemoteAction_Handler", ApiSince=37)]
public virtual Android.App.PictureInPictureParams.Builder SetOverlayActions(System.Collections.Generic.IList<Android.App.RemoteAction>? overlayActions, Android.App.RemoteAction? primaryOverlayAction);
[<Android.Runtime.Register("setOverlayActions", "(Ljava/util/List;Landroid/app/RemoteAction;)Landroid/app/PictureInPictureParams$Builder;", "GetSetOverlayActions_Ljava_util_List_Landroid_app_RemoteAction_Handler", ApiSince=37)>]
abstract member SetOverlayActions : System.Collections.Generic.IList<Android.App.RemoteAction> * Android.App.RemoteAction -> Android.App.PictureInPictureParams.Builder
override this.SetOverlayActions : System.Collections.Generic.IList<Android.App.RemoteAction> * Android.App.RemoteAction -> Android.App.PictureInPictureParams.Builder

參數

overlayActions
IList<RemoteAction>

要在畫中畫視窗疊加圖中顯示的動作。 通常,對於媒體應用程式,這個動作清單可以包含呼叫To-Action(CTA)和跳過動作。 這個值可能是 Null。

primaryOverlayAction
RemoteAction

在畫中畫視窗疊加中,動作將作為主要動作。 這個動作必須是透過 overlayActions 設定的其中一個動作。 例如,媒體應用程式可以在廣告播放時,用它來標示行動呼籲(CTA)按鈕。 這個值可能是 Null。

傳回

這個建構者實例。 這個值不可能為零值。

屬性

備註

設定覆蓋層動作和主要覆蓋層動作。 如果動作數超過 Activity.getMaxNumPictureInPictureOverlayActions() 數,輸入清單會被截斷為該數值。

與 setActions(List) 標準的動作不同,這些動作以明顯的覆蓋層呈現,使用者無需點擊視窗即可顯示選單。

Android 參考資料。android.app.PictureInPictureParams.Builder.setOverlayActions

本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。

適用於