API reference

PalmMenuExampleButtonHandlers Class

Extends MonoBehaviour
Example of a bespoke behavior created to react to a particular palm menu.
This controls the state of the object that responds to the menu, but also parts of the menu itself, specifically those which depend on the state of the controlled object (swappable icons, various text boxes, etc.).

Methods

CycleColor ()
Change the color of the controlled object to the next in the list of allowed colors, looping if the end of the list is reached.
Signature
void Oculus.Interaction.Samples.PalmMenu.PalmMenuExampleButtonHandlers.CycleColor()
Returns
void
CycleRotationDirection ()
Change the rotation direction of the controlled object to the next in the list of allowed directions, looping if the end of the list is reached.
Set the icon of the controlling button to display what will happen next time the button is pressed.
Signature
void Oculus.Interaction.Samples.PalmMenu.PalmMenuExampleButtonHandlers.CycleRotationDirection()
Returns
void
CycleShape ( cycleForward )
Change the shape of the controlled object to the next or previous in the list of allowed shapes, depending on the requested direction, looping beyond the bounds of the list.
Set the text to display the name of the current shape.
Signature
void Oculus.Interaction.Samples.PalmMenu.PalmMenuExampleButtonHandlers.CycleShape(bool cycleForward)
Parameters
cycleForward: bool
Returns
void
IncrementElevation ( up )
Change the target elevation of the controlled object in the requested direction, within the limits [0.2, 2].
Set the text to display the new target elevation.
Signature
void Oculus.Interaction.Samples.PalmMenu.PalmMenuExampleButtonHandlers.IncrementElevation(bool up)
Parameters
up: bool
Returns
void
ToggleRotationEnabled ()
Toggle whether or not rotation is enabled, and set the icon of the controlling button to display what will happen next time the button is pressed.
Signature
void Oculus.Interaction.Samples.PalmMenu.PalmMenuExampleButtonHandlers.ToggleRotationEnabled()
Returns
void