BorderControlModel

Implements the control elements for border values. This includes the color, width and style of the border. Note that the border radius is NOT part of this. The border control is used directly embedded in the sidebar but is also embedded in the advanced border popup.

Constructor

new BorderControlModel()

Methods

activate(initBorder)

If the border is just the default morphic border the controls are inactive. Activating the controls causes them to be initialized to a default initial border with width 1.

Parameters:
NameTypeDefaultDescription
initBorderBooleantrue

closePopup()

Closes the popup responsible for controlling the property.

confirm()

Update the current border value based on the inputs in the UI. This is invoked in response to user interactions.

deactivate()

Resets the border to the default border value of width 0. Consequently deactivates the border control for this focused morph.

focusOn()

Sets the current morph the effects control is focused on.

openPopup()

Opens the popup responsible for controlling the property.

update()

Refresh the UI to reflect the current border of the focused morph.

withBorder(borderValue)

Set the input elements to display the given border value.

Parameters:
NameTypeDescription
borderValueBorderValue

The value of the border (style, color, width) that is to be displayed.