Skip to main content

Class: FrequencyInput

An input with a scrolling cursor which allows users to select a radio frequency.

Hierarchy

Implements

Constructors

constructor

new FrequencyInput(props): FrequencyInput

Creates an instance of a DisplayComponent.

Parameters

NameTypeDescription
propsFrequencyInputPropsThe propertis of the component.

Returns

FrequencyInput

Inherited from

DisplayComponent<FrequencyInputProps>.constructor

Defined in

src/sdk/components/FSComponent.ts:73

Properties

context

Optional context: [] = undefined

The context on this component, if any.

Inherited from

DisplayComponent.context

Defined in

src/sdk/components/FSComponent.ts:64


contextType

Optional Readonly contextType: readonly [] = undefined

The type of context for this component, if any.

Inherited from

DisplayComponent.contextType

Defined in

src/sdk/components/FSComponent.ts:67


props

props: FrequencyInputProps & ComponentProps

The properties of the component.

Inherited from

DisplayComponent.props

Defined in

src/sdk/components/FSComponent.ts:61

Accessors

cursorPosition

get cursorPosition(): Subscribable<number>

The index of the character position currently selected by this input's cursor.

Returns

Subscribable<number>

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:124


isEditingActive

get isEditingActive(): Subscribable<boolean>

Whether editing is active for this input.

Returns

Subscribable<boolean>

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:130


isSelectionPerSlot

get isSelectionPerSlot(): Subscribable<boolean>

Whether this input's cursor selection mode is per-slot.

Returns

Subscribable<boolean>

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:136

Methods

activateEditing

activateEditing(isSelectionPerSlot): void

Activates editing for this input.

Parameters

NameTypeDescription
isSelectionPerSlotbooleanWhether cursor selection should be initialized to per-slot mode. If false, cursor selection will be initialized to per-character mode instead.

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:281


backspace

backspace(): void

Removes the character at the cursor's current position. If backfill is allowed, this will also shift all non-empty characters to the left of the cursor's current position one position to the right. If backfill is not allowed, this will shift the cursor one position to the left after the character is removed.

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:408


changeSlotValue

changeSlotValue(direction): void

Increments or decrements the value of the slot currently selected by the cursor. If editing is not active, it will be activated instead of changing any slot value. If cursor selection is in per-character mode, it will be forced to per-slot mode. If the cursor is past the last slot, this method does nothing.

Parameters

NameTypeDescription
direction1 | -1The direction in which to change the slot value (1 = increment, -1 = decrement).

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:328


deactivateEditing

deactivateEditing(): void

Deactivates editing for this input.

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:295


destroy

destroy(): void

Returns

void

Inherit Doc

Overrides

DisplayComponent.destroy

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:724


getContext

getContext(context): never

Gets a context data subscription from the context collection.

Parameters

NameTypeDescription
contextneverThe context to get the subscription for.

Returns

never

The requested context.

Throws

An error if no data for the specified context type could be found.

Inherited from

DisplayComponent.getContext

Defined in

src/sdk/components/FSComponent.ts:106


isInitialized

isInitialized(): boolean

Checks whether this input is initialized.

Returns

boolean

Whether this input is initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:241


moveCursor

moveCursor(direction, forceSelectionPerSlot): void

Moves the cursor.

Parameters

NameTypeDescription
direction1 | -1The direction in which to move (1 = to the right, -1 = to the left).
forceSelectionPerSlotbooleanWhether to force cursor selection to per slot mode.

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:311


onAfterRender

onAfterRender(thisNode): void

Parameters

NameType
thisNodeVNode

Returns

void

Inherit Doc

Overrides

DisplayComponent.onAfterRender

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:145


onBeforeRender

onBeforeRender(): void

A callback that is called before the component is rendered.

Returns

void

Inherited from

DisplayComponent.onBeforeRender

Defined in

src/sdk/components/FSComponent.ts:80


onUiInteractionEvent

onUiInteractionEvent(event): boolean

Handles a UiInteractionEvent.

Parameters

NameTypeDescription
eventUiInteractionEventThe event to handle.

Returns

boolean

Whether the event was handled.

Implementation of

UiInteractionHandler.onUiInteractionEvent

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:453


populateCharsFromValue

populateCharsFromValue(): void

Populates all of this input's character positions with non-empty values, if possible, using this input's value digitizer function and the current composite value as a template.

Returns

void

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:422


refresh

refresh(): void

Refreshes this input, updating the size and position of the cursor.

Returns

void

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:430


render

render(): VNode

Returns

VNode

Inherit Doc

Overrides

DisplayComponent.render

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:548


setFrequency

setFrequency(freq): number

Sets the frequency value of this slot. As part of the operation, all of this slot's characters will be set to non-null representations of the new slot value, if possible. The frequency value of this slot after the operation is complete may differ from the requested value depending on whether the requested value can be accurately represented by this slot.

Parameters

NameTypeDescription
freqnumberThe new frequency value, in hertz.

Returns

number

The frequency value of this input after the operation is complete.

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:254


setSlotCharacterValue

setSlotCharacterValue(value): void

Sets the value of the slot character currently selected by the cursor. If editing is not active, it will be activated before setting the value. If cursor selection is in per-slot mode, it will be forced to per-character mode, and the first character of the slot will be selected before setting the value. If the cursor is past the last slot, this method does nothing.

Parameters

NameTypeDescription
valuestringThe value to set.

Returns

void

Throws

Error if this input is not initialized.

Defined in

src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Components/FrequencyInput/FrequencyInput.tsx:346