API Docs for: 1.4.4
Show:

ugsChordBuilder.editorUi Class

Doing

Constructor

ugsChordBuilder.editorUi

()

Methods

() Void private

Returns:

Void:

convertDots

(
  • startingFret
  • builderDots
)
Array

Converts standard scriptasaurus Dot array to chordBuilder dot array (fret changes)

Parameters:

  • startingFret Int
  • builderDots Array

Returns:

Array:

findMaxFret

(
  • dots
)
Ing

Loops over dots to find the largest fret value

Parameters:

  • dots Array

Returns:

Ing:

() Void private

Returns:

Void:

() Void private

Returns:

Void:

() Void private

Returns:

Void:

init

() Bool

Returns FALSE if canvas is not supported

Returns:

Bool:

() Void private

Returns:

Void:

() Void private

Returns:

Void:

() Void private

Needs to watch for closed chords!

Returns:

Void:

() Void private

Returns:

Void:

() Void private

Returns:

Void:

() Void private

Yet another poor man's jQuery envying add/remove CSS class method.

Returns:

Void:

() Void private

Returns:

Void:

onCancelClick

()

Cancel button's click event handler

onSaveClick

()

Save button's click event handler

reset

(
  • name
  • startingFret
  • dots
  • isNew
)

Does a complete UI reset (if no values provided in params), otherwise this is kinda a "set"

Parameters:

  • name String

    Chord name

  • startingFret Int
  • dots Array
  • isNew Bool

    Used to set the button text

resetCurrentTool

()

Updates the Toolbox's current tool to be "Add Dot"; sets properties required for cursor, etc.

resetInputs

(
  • name
  • startingFret
  • isNew
)
Void

Updates the "standard form-like inputs"

Parameters:

  • name String
  • startingFret Int
  • isNew Bool

Returns:

Void:

setChord

(
  • chord
)

DANGER!! this is really a public method! A reference to this is passed to the scrapper during its initialization. Used to load ths Chord Builder

Parameters:

  • chord Chord

updateFinger

() Void private

Successively clicking the Finger tool cycles through index to pinky, then none, and so on. This method automatically increments the "currently active finger" (odd sentence, that) and updates the toolbox UI. Note: changing the cursor is not handled here.

Returns:

Void:

() Void private

Returns:

Void:

Attributes

_fingerNames

JSON

A "reverse Enum" dictionary of finger number to description