tweak.EntriesPanel Extends
The body of the tweaks UI and also used for BooleanGroup.

Inheritance

Constructor

goog.tweak.EntriesPanel(entriesopt_domHelper)

Parameters

entries : !Array.<!goog.tweak.BaseEntry>
The entries to show in the panel.
opt_domHelper : goog.dom.DomHelper=
The DomHelper to render with.

Instance Methods

Public Protected Private
boundHelpOnClickHandler_()
The bound onclick handler for the help question marks.
code »
createBooleanSettingDom_(tweaklabel) !DocumentFragment
Creates the DOM element to control the given boolean setting.
Arguments:
tweak : !goog.tweak.BooleanSetting
The setting.
label : string
The label for the entry.
Returns: !DocumentFragment  The DOM elements.
code »
createButtonActionDom_(tweaklabel) !Element
Creates the DOM element to control the given button action.
Arguments:
tweak : !goog.tweak.ButtonAction
The action.
label : string
The label for the entry.
Returns: !Element  The DOM element.
code »
createComboBoxDom_(tweaklabelonchangeFunc) !DocumentFragment
Creates the DOM element to control the given enum setting.
Arguments:
tweak : !goog.tweak.StringSetting | !goog.tweak.NumericSetting
The setting.
label : string
The label for the entry.
onchangeFunc : !Function
onchange event handler.
Returns: !DocumentFragment  The DOM element.
code »
createEntryElem_(entry) !Element
Creates and returns a form element for the given entry.
Arguments:
entry : !goog.tweak.BaseEntry
The entry.
Returns: !Element  The root DOM element for the entry.
code »
createHelpElem_(entry) !Element
Creates and returns a help element for the given entry.
Arguments:
entry : goog.tweak.BaseEntry
The entry.
Returns: !Element  The root element of the created DOM.
code »
createSubPanelDom_(entrylabelchildEntries) !DocumentFragment
Creates the DOM for a BooleanGroup or NamespaceEntry.
Arguments:
entry : !goog.tweak.BooleanGroup | !goog.tweak.NamespaceEntry_
The entry.
label : string
The label for the entry.
childEntries : !Array.<goog.tweak.BaseEntry>
The child entries.
Returns: !DocumentFragment  The DOM element.
code »
createTextBoxDom_(tweaklabelonchangeFunc) !DocumentFragment
Creates the DOM element to control the given string setting.
Arguments:
tweak : !goog.tweak.StringSetting | !goog.tweak.NumericSetting
The setting.
label : string
The label for the entry.
onchangeFunc : !Function
onchange event handler.
Returns: !DocumentFragment  The DOM element.
code »
createTweakEntryDom_(entry) !Element | !DocumentFragment
Creates the DOM element to control the given entry.
Arguments:
entry : !goog.tweak.BaseEntry
The entry.
Returns: !Element | !DocumentFragment  The DOM element.
code »
getRootElement() !Element
No description.
Returns: !Element  Returns the expanded element. Must not be called before render().
code »
insertEntry(entry)
Inserts the given entry into the panel.
Arguments:
entry : !goog.tweak.BaseEntry
The entry to insert.
code »
onHelpClick_(entryDiv)
Click handler for the help link.
Arguments:
entryDiv : Node
The div that contains the tweak.
code »
render(opt_endElement) !Element
Creates and returns the expanded element. The markup looks like:
Show Descriptions
... {endElement}
Arguments:
opt_endElement : Element | DocumentFragment=
Element to insert after all tweak entries.
Returns: !Element  The root element for the panel.
code »
showDescription_(entryDivshow)
Twiddle the DOM so that the entry within the given span is shown/hidden.
Arguments:
entryDiv : Node
The div that contains the tweak.
show : boolean
True to show, false to hide.
code »
toggleAllDescriptions()
Show all entry descriptions (has the same effect as clicking on all ?'s).
code »

Instance Properties

childPanels :
Map of tweak ID -> EntriesPanel for child panels (BooleanGroups).
Code »
domHelper_ : goog.dom.DomHelper
The DomHelper to render with.
Code »
entries_ :
The entries to show in the panel.
Code »
mainPanel_ :
The element that contains all of the settings and the endElement.
Code »
rootElem_ :
The element that contains the UI.
Code »
showAllDescriptionsState_ :
Flips between true/false each time the "Toggle Descriptions" link is clicked.
Code »

Package tweak

Package Reference