UIBarHandler
UI bar handler component exposed by the Java runtime.
Create in the Editor
- Ensure there is a
UIControllerin the scene. - Create a GameObject and add
UIRect. - Add the
UIBarHandlercomponent.
How to Use
- Get the component with
myObject.findComponent(UIBarHandler.class). - Read or write the component properties to control behavior.
- Test input or layout in Play mode.
Java Example
SpatialObject myObject = /* your object */;
UIBarHandler comp = myObject.findComponent(UIBarHandler.class);
if (comp != null) {
// set the align value:
comp.align = UIBarHandler.Align.Center;
// read the align value:
UIBarHandler.Align alignValue = comp.align;
}