語言

ActionBar.SetHomeActionContentDescription 方法

定義

多載

名稱 Description
SetHomeActionContentDescription(ICharSequence)

啟用後,為 Home/Up 動作設定替代描述。

SetHomeActionContentDescription(Int32)

啟用後,為 Home/Up 動作設定替代描述。

SetHomeActionContentDescription(String)

啟用後,為 Home/Up 動作設定替代描述。

SetHomeActionContentDescription(ICharSequence)

啟用後,為 Home/Up 動作設定替代描述。

[Android.Runtime.Register("setHomeActionContentDescription", "(Ljava/lang/CharSequence;)V", "GetSetHomeActionContentDescription_Ljava_lang_CharSequence_Handler")]
public virtual void SetHomeActionContentDescription(Java.Lang.ICharSequence? description);
[<Android.Runtime.Register("setHomeActionContentDescription", "(Ljava/lang/CharSequence;)V", "GetSetHomeActionContentDescription_Ljava_lang_CharSequence_Handler")>]
abstract member SetHomeActionContentDescription : Java.Lang.ICharSequence -> unit
override this.SetHomeActionContentDescription : Java.Lang.ICharSequence -> unit

參數

description
ICharSequence

啟用後,Home 動作的新描述

屬性

備註

啟用後,為 Home/Up 動作設定替代描述。 此描述通常用於啟用 Home 動作時的無障礙/螢幕閱讀器。 (參見 setDisplayHomeAsUpEnabled(布林值)。) 例如,根據DISPLAY_HOME_AS_UP顯示選項,會顯示「導航回家」或「向上導航」。 如果你用 setHomeAsUpIndicator(int) 更改了 home-as-up 指示器來指示更具體的功能,例如滑動抽屜,你也應該設定它來準確描述動作。

將此設定為 null 會使用系統預設的描述。

另請參閱:

Android 參考資料。android.app.ActionBar.setHomeActionContentDescription

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

適用於

SetHomeActionContentDescription(Int32)

啟用後,為 Home/Up 動作設定替代描述。

[Android.Runtime.Register("setHomeActionContentDescription", "(I)V", "GetSetHomeActionContentDescription_IHandler")]
public virtual void SetHomeActionContentDescription(int resId);
[<Android.Runtime.Register("setHomeActionContentDescription", "(I)V", "GetSetHomeActionContentDescription_IHandler")>]
abstract member SetHomeActionContentDescription : int -> unit
override this.SetHomeActionContentDescription : int -> unit

參數

resId
Int32

一個字串的資源 ID,當啟用後用作 Home 動作的新描述

屬性

備註

啟用後,為 Home/Up 動作設定替代描述。 此描述通常用於啟用 Home 動作時的無障礙/螢幕閱讀器。 (參見 setDisplayHomeAsUpEnabled(布林值)。) 例如,根據DISPLAY_HOME_AS_UP顯示選項,會顯示「導航回家」或「向上導航」。 如果你用 setHomeAsUpIndicator(int) 更改了 home-as-up 指示器來指示更具體的功能,例如滑動抽屜,你也應該設定它來準確描述動作。

將此設定為 0 會使用系統預設的描述。

另請參閱:

Android 參考資料。android.app.ActionBar.setHomeActionContentDescription

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

適用於

SetHomeActionContentDescription(String)

啟用後,為 Home/Up 動作設定替代描述。

public void SetHomeActionContentDescription(string? description);
member this.SetHomeActionContentDescription : string -> unit

參數

description
String

啟用後,Home 動作的新描述

備註

啟用後,為 Home/Up 動作設定替代描述。 此描述通常用於啟用 Home 動作時的無障礙/螢幕閱讀器。 (參見 setDisplayHomeAsUpEnabled(布林值)。) 例如,根據DISPLAY_HOME_AS_UP顯示選項,會顯示「導航回家」或「向上導航」。 如果你用 setHomeAsUpIndicator(int) 更改了 home-as-up 指示器來指示更具體的功能,例如滑動抽屜,你也應該設定它來準確描述動作。

將此設定為 null 會使用系統預設的描述。

另請參閱:

Android 參考資料。android.app.ActionBar.setHomeActionContentDescription

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

適用於