Share via


Ringtone.SetHapticGeneratorEnabled(Boolean) Method

Definition

Enable or disable the android.media.audiofx.HapticGenerator effect.

[Android.Runtime.Register("setHapticGeneratorEnabled", "(Z)Z", "GetSetHapticGeneratorEnabled_ZHandler", ApiSince=31)]
public virtual bool SetHapticGeneratorEnabled (bool enabled);
[<Android.Runtime.Register("setHapticGeneratorEnabled", "(Z)Z", "GetSetHapticGeneratorEnabled_ZHandler", ApiSince=31)>]
abstract member SetHapticGeneratorEnabled : bool -> bool
override this.SetHapticGeneratorEnabled : bool -> bool

Parameters

enabled
Boolean

Returns

true if the HapticGenerator effect is successfully enabled. Otherwise, return false.

Attributes

Remarks

Enable or disable the android.media.audiofx.HapticGenerator effect. The effect can only be enabled on devices that support the effect.

Java documentation for android.media.Ringtone.setHapticGeneratorEnabled(boolean).

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