Difference between revisions of "GUIDropdownComponent"

From Virtual World Web Wiki
Jump to: navigation, search
(Documentation for the GUIDropdownComponent class)
(Documentation for the GUIDropdownComponent class)
Line 1: Line 1:
Abstract class representing components which open to have a panel of subobjects when clicked
 
 
 
*'''Inherits class: [[GUISelectableComponent]]'''
 
*'''Inherits class: [[GUISelectableComponent]]'''
 
* This is a JavaScript visible object
 
* This is a JavaScript visible object
Line 8: Line 6:
 
===Properties===
 
===Properties===
 
:{{CSharp|float AnimationDelaySeconds {get; set;} }}
 
:{{CSharp|float AnimationDelaySeconds {get; set;} }}
::
 
::How long to wait for the reveal/disappear animation to complete
 
  
 
:{{CSharp|string DisappearAnimation {get; set;} }}
 
:{{CSharp|string DisappearAnimation {get; set;} }}
::
 
::Disappear animation to use from the animator when hiding (note: only Disappear01 right now)
 
  
 
:{{CSharp|string MenuItemTemplate {get; set;} }}
 
:{{CSharp|string MenuItemTemplate {get; set;} }}
::
 
::Template to use for creating subcomponents by default
 
  
 
:{{CSharp|bool MenuVisible {get; set;} }}
 
:{{CSharp|bool MenuVisible {get; set;} }}
::
 
::Hide/Show the panel of sub components
 
  
 
:{{CSharp|GUIPanel Panel {get;} }}
 
:{{CSharp|GUIPanel Panel {get;} }}
::
 
::Reference to the panel which holds the subcomponents
 
  
 
:{{CSharp|GUISprite PanelSprite {get;} }}
 
:{{CSharp|GUISprite PanelSprite {get;} }}
::
 
::Reference to the sprite on the back of the Panel
 
  
 
:{{CSharp|JSVector2 PopupOffset {get; set;} }}
 
:{{CSharp|JSVector2 PopupOffset {get; set;} }}
::
 
::Offset to place the panel from the parent button
 
  
 
:{{CSharp|string RevealAnimation {get; set;} }}
 
:{{CSharp|string RevealAnimation {get; set;} }}
::
 
::Reveal animation to use from the animator when showing (note: only Appear01 right now)
 
  
 
===Events===
 
===Events===
 
:{{CSharp|OnClosing()}}
 
:{{CSharp|OnClosing()}}
::
 
::Event fired when we stop showing subcomponents
 
  
 
:{{CSharp|OnDone()}}
 
:{{CSharp|OnDone()}}
::
 
::Event fired when we choose a subcomponent
 
  
 
:{{CSharp|OnOpening()}}
 
:{{CSharp|OnOpening()}}
::
 
::Event fired when we start showing subcomponents
 
  
 
===Methods===
 
===Methods===
 
:{{CSharp|void ClearItems()}}
 
:{{CSharp|void ClearItems()}}
::
 
::Remove all items from this component
 
  
 
:{{CSharp|IEnumerable<GUIComponent> GetDropDownItems()}}
 
:{{CSharp|IEnumerable<GUIComponent> GetDropDownItems()}}
::
 
::Returns a list of the components on the panel
 
  
 
:{{CSharp|GUIComponent GetItem(int i)}}
 
:{{CSharp|GUIComponent GetItem(int i)}}
::
 
::Returns the i'th item from the DropDownComponents collection.
 
  
 
__NOTOC____NOEDITSECTION__
 
__NOTOC____NOEDITSECTION__

Revision as of 14:16, 15 January 2018

Remarks [edit]

Properties

float AnimationDelaySeconds {get; set;}
string DisappearAnimation {get; set;}
string MenuItemTemplate {get; set;}
bool MenuVisible {get; set;}
GUIPanel Panel {get;}
GUISprite PanelSprite {get;}
JSVector2 PopupOffset {get; set;}
string RevealAnimation {get; set;}

Events

OnClosing()
OnDone()
OnOpening()

Methods

void ClearItems()
IEnumerable<GUIComponent> GetDropDownItems()
GUIComponent GetItem(int i)