File

src/services/tabOrderService/main-tab-order.service.ts

Index

Properties
Methods
Accessors

Methods

applyFocusToAvailableComponent
applyFocusToAvailableComponent(availableComponent: any, isShiftPressed: boolean, event: any)

Apply focus to all components in a window, gives a special treatment to dataManager controls and userObjects

Parameters :
Name Type Optional Description
availableComponent any No

Tab node component

isShiftPressed boolean No
event any No

The current javascript event

Returns : void
assignEmptyStartEndNodes
assignEmptyStartEndNodes(newNode: TabNode)

Method used by insert sort when there is no root node at the list

Parameters :
Name Type Optional Description
newNode TabNode No

Tab Node component

Returns : void
availableNextNode
availableNextNode(tabNodeReference: TabNode, isShiftPressed: boolean, length: number, isTabNodeReferenceRadioButton: boolean)

Availables next node

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The current tabnode reference

isShiftPressed boolean No

to detect if shift was pressed

length number No

the component list length

isTabNodeReferenceRadioButton boolean No
Returns : any

next node

getComponentById
getComponentById(id: string)

Gets a component by id

Parameters :
Name Type Optional Description
id string No

The WebMap id used to find the component

Returns : any

A component instance

getHead
getHead()

Gets the head node.

Returns : TabNode
getLowerTabIndexRadioButton
getLowerTabIndexRadioButton()

Gets the radiobutton component that has the lower TabOrder value

Returns : any

The nodeInstance for the radioButton if applies otherwise null

getSelectedRadioButton
getSelectedRadioButton(tabNodeReference: TabNode)

Gets the selected radiobutton for the current container

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tabNode

Returns : any

The selected radiobutton if there is at least one

insertBetweenNodes
insertBetweenNodes(firstNode: TabNode, secondNode: TabNode, newNode: TabNode)

Insert a new node at the middle of the list

Parameters :
Name Type Optional Description
firstNode TabNode No
secondNode TabNode No
newNode TabNode No

Tab Node component

Returns : void
insertEnd
insertEnd(newNode: TabNode)

Insert a new node at the end of the list and updates end Node reference

Parameters :
Name Type Optional Description
newNode TabNode No

Tab Node component

Returns : void
Private insertNodeFirstOrMiddle
insertNodeFirstOrMiddle(newNode: TabNode)

Insert the node when is not in the last position

Parameters :
Name Type Optional
newNode TabNode No
Returns : void
insertSort
insertSort(newNode: TabNode)

This method is used to insert sort nodes in to a double linked circular list

Parameters :
Name Type Optional Description
newNode TabNode No

Tab node component

Returns : void
insertStart
insertStart(newNode: TabNode)

Insert a new node at the beginning of the list and updates start Node reference

Parameters :
Name Type Optional Description
newNode TabNode No

Tab Node component

Returns : void
isFocusableContainer
isFocusableContainer(tabNodeReference: TabNode)

Method to know if specifics container can gain focus and not only execute the enterContainer mechanism Is important for containers with this behavior to be registered on the focusableContainers dictionary and use the ContainerDirective to manage the tab behavior.

Example: TabControl component

Parameters :
Name Type Optional
tabNodeReference TabNode No
Returns : boolean

{boolean}

isLabelComponent
isLabelComponent(tabNodeReference: TabNode)

Determines if a tabNode is a labelComponent

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tabNode

Returns : boolean

True if it is a label otherwise false

isRadioButtonComponent
isRadioButtonComponent(tabNodeReference: TabNode)

Determines if a tabNode is a radioButtonComponent

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tabNode

Returns : boolean

True if it is a radioButton otherwise false

isReferenceAlive
isReferenceAlive(tabNodeReference: TabNode)

Returns true if the reference is alive otherwise false

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tab node refernced

Returns : boolean
isValidTabNode
isValidTabNode(tabNodeReference: TabNode, isTabNodeReferenceRadioButton: boolean, selectedRadioButton: any)

Determines whether a node instance is valid

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tabNode

isTabNodeReferenceRadioButton boolean No

Determines if the tabbed control is a radiobutton

selectedRadioButton any No

Contains the selected radioButton for the current container

Returns : boolean

true if valid tab node

registerContainerParentInstance
registerContainerParentInstance(control: any)

Method to register the Window or Container provider of the tab service

Parameters :
Name Type Optional
control any No
Returns : void
registerInstance
registerInstance(componentInstance: any)

Register a component instance into the service component list

Parameters :
Name Type Optional
componentInstance any No
Returns : void
resolveTab
resolveTab(tabNodeReference: TabNode, isShiftPressed: boolean, event: any)

Handle tab interaction

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

the current tabnode

isShiftPressed boolean No

to detect if is reverse tab

event any No

the current javascript event object

Returns : void
unregisterInstance
unregisterInstance(componentInstance: any, id?: string)
Parameters :
Name Type Optional
componentInstance any No
id string Yes
Returns : void
Private validatePosition
validatePosition(previousEndFlag: TabNode, newNode: TabNode, endFlag: TabNode)

Validate the position of the node

Parameters :
Name Type Optional
previousEndFlag TabNode No
newNode TabNode No
endFlag TabNode No
Returns : void
validateRadioButtons
validateRadioButtons(tabNodeReference: TabNode, isTabNodeReferenceRadioButton: boolean, selectedRadioButton: any)

Validates if the tabNode is valid radioButton to receive the focus

Parameters :
Name Type Optional Description
tabNodeReference TabNode No

The tabNode

isTabNodeReferenceRadioButton boolean No

Determines if the tabbed control is a radiobutton

selectedRadioButton any No

Contains the selected radioButton for the current container

Returns : boolean

True if it is valid otherwise false

Properties

Protected containerParentInstance
Type : any

The instance of the container parent of the tab service

Protected head
Type : TabNode

Head of main tab order service list

Protected nodesInstances
Type : IDictionary
Default value : new Dictionary()
Protected tail
Type : TabNode

Tail of main tab order service

Accessors

length
getlength()

Length of main tab order service

Returns : number

results matching ""

    No results matching ""