Class: WT21FmcScreen
WT21 FMC screen
Hierarchy
FmcScreen
<WT21FmcPage
<any
>,WT21FmcEvents
>↳
WT21FmcScreen
Constructors
constructor
• new WT21FmcScreen(bus
, baseInstrument
, fms
, fmcIndex
, targetElement
): WT21FmcScreen
Ctor
Parameters
Name | Type | Description |
---|---|---|
bus | EventBus | the event bus |
baseInstrument | WT21_FMC_Instrument | the FMC base instrument |
fms | WT21Fms | the fms |
fmcIndex | 1 | 2 | the fmc index |
targetElement | HTMLDivElement | the cdu render target element |
Returns
Overrides
FmcScreen\<WT21FmcPage\<any\>, WT21FmcEvents\>.constructor
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/WT21FmcScreen.ts:58
Properties
bus
• Protected
Readonly
bus: EventBus
the event bus
Inherited from
FmcScreen.bus
Defined in
sdk/fmc/FmcScreen.ts:100
currentlyDisplayedPage
• Protected
currentlyDisplayedPage: null
| WT21FmcPage
<any
> = null
Inherited from
FmcScreen.currentlyDisplayedPage
Defined in
sdk/fmc/FmcScreen.ts:83
fmcIndex
• Readonly
fmcIndex: 1
| 2
the fmc index
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/WT21FmcScreen.ts:58
options
• Readonly
options: Required
<FmcScreenOptions
>
Inherited from
FmcScreen.options
Defined in
sdk/fmc/FmcScreen.ts:71
scratchpad
• Readonly
scratchpad: FmcScratchpad
the scratchpad to use for this screen
Inherited from
FmcScreen.scratchpad
Defined in
sdk/fmc/FmcScreen.ts:104
Accessors
currentRoute
• get
currentRoute(): Subject
<string
>
Gets the current route
Returns
Subject
<string
>
a string subject
Inherited from
FmcScreen.currentRoute
Defined in
sdk/fmc/FmcScreen.ts:138
currentSubpageCount
• get
currentSubpageCount(): Subject
<number
>
Gets the current number of subpages for the current displayed page
Returns
Subject
<number
>
a number
Inherited from
FmcScreen.currentSubpageCount
Defined in
sdk/fmc/FmcScreen.ts:156
currentSubpageIndex
• get
currentSubpageIndex(): Subject
<number
>
Gets the current subpage index for the current displayed page, 1-indexed
Returns
Subject
<number
>
a number
Inherited from
FmcScreen.currentSubpageIndex
Defined in
sdk/fmc/FmcScreen.ts:147
Methods
acceptPageOutput
▸ acceptPageOutput(output
, template
, atRowIndex
): void
Method called when a page is rendered to the screen. This can be overridden to intercept the page data and act upon it.
Parameters
Name | Type | Description |
---|---|---|
output | FmcOutputTemplate | the output template, displayed on the screen |
template | FmcRenderTemplate | the render template, rendered by the page |
atRowIndex | number | the row index at which the render occurred |
Returns
void
Inherited from
FmcScreen.acceptPageOutput
Defined in
sdk/fmc/FmcScreen.ts:400
addLskEvents
▸ addLskEvents(array
): void
Adds a list of LSK events bound to certain positions on the rendering grid
Parameters
Name | Type | Description |
---|---|---|
array | [event: BTN_A | BTN_B | BTN_C | BTN_D | BTN_E | BTN_F | BTN_G | BTN_H | BTN_I | BTN_J | BTN_K | BTN_L | BTN_M | BTN_N | BTN_O | BTN_P | BTN_Q | BTN_R | BTN_S | BTN_T | BTN_U | BTN_V | BTN_W | BTN_X | BTN_Y | BTN_Z | BTN_1 | BTN_2 | BTN_3 | BTN_4 | BTN_5 | BTN_6 | BTN_7 | BTN_8 | BTN_9 | BTN_0 | BTN_PLUSMINUS | BTN_SP | BTN_DIV | BTN_DOT | BTN_CLR_DEL | BTN_CLR_DEL_LONG | BTN_PLUS_MINUS | BTN_EXEC | PAGE_INDEX | PAGE_STATUS | PAGE_LEGS | PAGE_MCDUMENU | PAGE_DSPLMENU1 | PAGE_MFDADV | PAGE_MFDDATA | PAGE_DIR | PAGE_FPLN | PAGE_POSINIT | PAGE_PERF | PAGE_PERFINIT | PAGE_TAKEOFFREF | PAGE_APPROACHREF1 | PAGE_VNAVSETUP | PAGE_FUELMGMT1 | PAGE_FUELMGMT2 | PAGE_FUELMGMT3 | PAGE_FLTLOG | PAGE_DEPARRIDX | PAGE_DEPART | PAGE_ARRIVAL | PAGE_DATALINKMENU | PAGE_WEATHER | PAGE_TERMWX_REQ | PAGE_TERMWX_VIEW | PAGE_VORDMECTL | PAGE_GNSSCTL | PAGE_GNSS1POS | PAGE_FREQ | PAGE_FIX | PAGE_PROG | PAGE_MSG | PAGE_TUNE | PAGE_DEFAULTS | PAGE_USERSETTINGS | LSK_1 | LSK_2 | LSK_3 | LSK_4 | LSK_5 | LSK_6 | RSK_1 | RSK_2 | RSK_3 | RSK_4 | RSK_5 | RSK_6 | BTN_PREV | BTN_NEXT | "scratchpad_type" | "scratchpad_plus_minus" | "clear_del" | "clear_del_long", row: number, col: number][] | the LSK events and their positions |
Returns
void
Inherited from
FmcScreen.addLskEvents
Defined in
sdk/fmc/FmcScreen.ts:329
addPageRoute
▸ addPageRoute<T
>(route
, page
, routeEvent?
): void
Declares a route for a page class
Type parameters
Name | Type |
---|---|
T | extends null |
Parameters
Returns
void
Inherited from
FmcScreen.addPageRoute
Defined in
sdk/fmc/FmcScreen.ts:251
▸ addPageRoute<U
>(route
, page
, routeEvent
, defaultProps
): void
Declares a route for a page class
Type parameters
Name | Type |
---|---|
U | extends PageConstructor <WT21FmcPage <any >, null > |
Parameters
Returns
void
Inherited from
FmcScreen.addPageRoute
Defined in
sdk/fmc/FmcScreen.ts:264
addPagingEvents
▸ addPagingEvents(events
): void
Adds paging events bound the page slewing
Parameters
Name | Type | Description |
---|---|---|
events | FmcPagingEvents <WT21FmcEvents > | the events to bind |
Returns
void
Inherited from
FmcScreen.addPagingEvents
Defined in
sdk/fmc/FmcScreen.ts:342
addPluginPageRoute
▸ addPluginPageRoute<T
>(route
, page
, routeEvent?
, defaultTypedParameters?
): void
Type parameters
Name | Type |
---|---|
T | extends object |
Parameters
Returns
void
Inherit Doc
Inherited from
FmcScreen.addPluginPageRoute
Defined in
sdk/fmc/FmcScreen.ts:299
attachPageExtension
▸ attachPageExtension(pageClass
, extensionCtor
): void
Parameters
Name | Type |
---|---|
pageClass | PageConstructor <WT21FmcPage <any >, null > |
extensionCtor | (...args : any []) => AbstractFmcPageExtension <WT21FmcPage <any >> |
Returns
void
Inherit Doc
Inherited from
FmcScreen.attachPageExtension
Defined in
sdk/fmc/FmcScreen.ts:319
clearScratchpad
▸ clearScratchpad(): void
Clears the scratchpad, if applicable
Returns
void
Inherited from
FmcScreen.clearScratchpad
Defined in
sdk/fmc/FmcScreen.ts:240
editOutputTemplate
▸ editOutputTemplate(rowIndex
, output
): void
Edits part of the screen output
Parameters
Name | Type | Description |
---|---|---|
rowIndex | number | the row index to insert at |
output | FmcOutputTemplate | the output to insert |
Returns
void
Throws
if rowIndex
is too high
Inherited from
FmcScreen.editOutputTemplate
Defined in
sdk/fmc/FmcScreen.ts:368
navigateTo
▸ navigateTo(route
, params?
): void
Navigates to a given route and displays the associated page, if available
Parameters
Name | Type | Description |
---|---|---|
route | string | the route |
params? | Record <string , unknown > | the parameters to pass to the page |
Returns
void
Inherited from
FmcScreen.navigateTo
Defined in
sdk/fmc/FmcScreen.ts:166
▸ navigateTo<U
>(pageClass
, props
): void
Navigates to a given route and displays the associated page, if available
Type parameters
Name | Type |
---|---|
U | extends PageConstructor <WT21FmcPage <any >, null > |
Parameters
Name | Type | Description |
---|---|---|
pageClass | U | the page's class |
props | U extends PageConstructor <AbstractFmcPage <V >, V > ? V : never | props to pass in to the page |
Returns
void
Inherited from
FmcScreen.navigateTo
Defined in
sdk/fmc/FmcScreen.ts:176
onLineSelectKeyError
▸ onLineSelectKeyError(error
): void
Called when an LSK error is thrown. Sets this.scratchpad.errorContents
(if error is a string; otherwise throws) by default.
Parameters
Name | Type | Description |
---|---|---|
error | any | the LSK error |
Returns
void
Inherited from
FmcScreen.onLineSelectKeyError
Defined in
sdk/fmc/FmcScreen.ts:466
onLineSelectKeyUnhandled
▸ onLineSelectKeyUnhandled(selectKeyEvent
): void
Called when an LSK event is not handled by any code.
Parameters
Name | Type | Description |
---|---|---|
selectKeyEvent | LineSelectKeyEvent | the LSK event |
Returns
void
Throws
the value of options.lskNotHandledThrowValue
by default
Inherited from
FmcScreen.onLineSelectKeyUnhandled
Defined in
sdk/fmc/FmcScreen.ts:456
onPrefixedEvent
▸ onPrefixedEvent<k
>(event
): Consumer
<WT21FmcEvents
[k
]>
Returns a consumer for an event prefixed for this particular screen.
Type parameters
Parameters
Name | Type | Description |
---|---|---|
event | k | The event to subscribe to. |
Returns
Consumer
<WT21FmcEvents
[k
]>
A consumer for an event prefixed for this particular screen.
Inherited from
FmcScreen.onPrefixedEvent
Defined in
sdk/fmc/FmcScreen.ts:356
processPluginPageAdditions
▸ processPluginPageAdditions(): void
Processes page replacement calls made by plugins. Must be called after plugins are initialized, and before stock routes are added.
Returns
void
Inherited from
FmcScreen.processPluginPageAdditions
Defined in
sdk/fmc/FmcScreen.ts:118
processPluginPageReplacements
▸ processPluginPageReplacements(): void
Processes page replacement calls made by plugins. Must be called after plugins are initialized, and after stock routes are added.
Returns
void
Inherited from
FmcScreen.processPluginPageReplacements
Defined in
sdk/fmc/FmcScreen.ts:127
replacePageRoute
▸ replacePageRoute<T
>(route
, page
, routeEvent?
, defaultTypedParameters?
): void
Type parameters
Name | Type |
---|---|
T | extends object |
Parameters
Returns
void
Inherit Doc
Inherited from
FmcScreen.replacePageRoute
Defined in
sdk/fmc/FmcScreen.ts:309
selectWptFromIdent
▸ selectWptFromIdent<F
>(ident
, referencePos
, filter?
): Promise
<null
| SearchTypeMap
[F
]>
Runs the flow to select a facility based on the given ident.
Type parameters
Name | Type |
---|---|
F | extends All | Airport | Intersection | Vor | Ndb | User | Visual | AllExceptVisual = All |
Parameters
Name | Type | Description |
---|---|---|
ident | string | The ident to search for. |
referencePos | GeoPointInterface | The reference position to use to sort multiple matching facilities. Facilities are sorted in order of increasing distance from the reference position. |
filter? | F | the filter to apply to the facility search. |
Returns
Promise
<null
| SearchTypeMap
[F
]>
The selected facility or null.
Defined in
workingtitle-instruments-wt21/instruments/html_ui/Pages/VCockpit/Instruments/WT21/FMC/WT21FmcScreen.ts:113