The Apple.Feedback namespace allows you to trigger iOS haptic feedback actions. Haptic feedback provides a tactile response, such as a tap, that draws attention and reinforces both actions and events.
Always use feedback for its intended purpose. Don't select a haptic because of the way it feels.
The Apple.Feedback API only generates haptic actions on iOS devices with a supported "Taptic" engine and when the "System Haptics" device setting is enabled.
On other devices, and in the Zing simulator, calling these methods will have no effect.
Use selection feedback to communicate movement through a series of discrete values or to indicate a change in selection.
Use impact feedback to indicate that an impact has occurred. For example, you might trigger impact feedback when a user interface object collides with another object or snaps into place.
The style parameter indicates the "mass" of the objects in the collision simulated.
A collision between small, light user interface elements.
A collision between moderately sized user interface elements.
A collision between large, heavy user interface elements.
Use notification feedback to communicate that a task or action has succeeded, failed, or produced a warning of some kind.
The type parameter controls the type of notification feedback generated.
A notification feedback type, indicating that a task has failed.
A notification feedback type, indicating that a task has completed successfully.
A notification feedback type, indicating that a task has produced a warning.