Udostępnij za pośrednictwem


PhoneStateListener.OnDisplayInfoChanged(TelephonyDisplayInfo) Method

Definition

Callback invoked when the display info has changed on the registered subscription.

[Android.Runtime.Register("onDisplayInfoChanged", "(Landroid/telephony/TelephonyDisplayInfo;)V", "GetOnDisplayInfoChanged_Landroid_telephony_TelephonyDisplayInfo_Handler", ApiSince=30)]
[Android.Runtime.RequiresPermission("android.permission.READ_PHONE_STATE")]
public virtual void OnDisplayInfoChanged (Android.Telephony.TelephonyDisplayInfo telephonyDisplayInfo);
[<Android.Runtime.Register("onDisplayInfoChanged", "(Landroid/telephony/TelephonyDisplayInfo;)V", "GetOnDisplayInfoChanged_Landroid_telephony_TelephonyDisplayInfo_Handler", ApiSince=30)>]
[<Android.Runtime.RequiresPermission("android.permission.READ_PHONE_STATE")>]
abstract member OnDisplayInfoChanged : Android.Telephony.TelephonyDisplayInfo -> unit
override this.OnDisplayInfoChanged : Android.Telephony.TelephonyDisplayInfo -> unit

Parameters

telephonyDisplayInfo
TelephonyDisplayInfo

The display information.

Attributes

Remarks

Callback invoked when the display info has changed on the registered subscription.

The TelephonyDisplayInfo contains status information shown to the user based on carrier policy.

For clients compiled on Android 11 SDK, requires permission: android.Manifest.permission#READ_PHONE_STATE or that the calling app has carrier privileges (see TelephonyManager#hasCarrierPrivileges). For clients compiled on Android 12 SDK or newer, android.Manifest.permission#READ_PHONE_STATE or carrier privileges is not required anymore.

This member is deprecated. Use TelephonyCallback.DisplayInfoListener instead.

Java documentation for android.telephony.PhoneStateListener.onDisplayInfoChanged(android.telephony.TelephonyDisplayInfo).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to