package ch.dissem.yaep.ui.common.focus

class LinearFocusable(
    manager: LinearSelectionManager,
    primaryAction: (() -> Unit)?,
    secondaryAction: (() -> Unit)?
) : Focusable<LinearFocusable>(manager, primaryAction, secondaryAction) {

    var previous: LinearFocusable = this
        private set

    private var _next: LinearFocusable = this
    var next: LinearFocusable
        get() = _next
        set(value) {
            previous = value.previous
            previous._next = this
            value.previous = this
            _next = value
        }
}