PC Stable Documentation
 
All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Loading...
Searching...
No Matches
OptionSelectorBase Class Reference

Private Member Functions

void OptionSelector (Widget parent, int current_index, ScriptedWidgetEventHandler parent_c, bool disabled)
 
void ~OptionSelector ()
 
override bool OnMouseButtonUp (Widget w, int x, int y, int button)
 
override bool OnClick (Widget w, int x, int y, int button)
 
override bool OnMouseEnter (Widget w, int x, int y)
 
override bool OnMouseLeave (Widget w, Widget enterW, int x, int y)
 
void Reset ()
 
void SetNextOption ()
 
void SetPrevOption ()
 
array< stringGetOptions ()
 
bool IsSet ()
 
bool IsEnabled ()
 Returns 'true' if current index == 1 (default 'enabled' value). Take care, as different selectors may follow different logic!
 
bool IsSelectorEnabled ()
 Returns false for the selector in 'disabled' states.
 
string GetStringValue ()
 
void SetStringOption (string option, bool fire_event=true)
 
void ColorOption ()
 
override bool IsFocusable (Widget w)
 
override void Enable ()
 
override void Disable ()
 
override void ColorNormalConsole (Widget w)
 
override void ColorDisabledConsole (Widget w)
 
void OptionSelectorEditbox (Widget parent, string value, ScriptedWidgetEventHandler parent_menu, bool disabled)
 
void ~OptionSelectorEditbox ()
 
override void Enable ()
 
override void Disable ()
 
override bool OnMouseEnter (Widget w, int x, int y)
 
override bool OnMouseLeave (Widget w, Widget enterW, int x, int y)
 
override bool OnChange (Widget w, int x, int y, bool finished)
 
override bool IsFocusable (Widget w)
 
override bool OnFocus (Widget w, int x, int y)
 
override bool OnFocusLost (Widget w, int x, int y)
 
void SetValue (string value, bool update=true)
 
string GetValue ()
 
override void ColorHighlight (Widget w)
 
override void ColorNormal (Widget w)
 
void ~OptionSelectorSliderSetup ()
 
override void Enable ()
 
override void Disable ()
 
override bool OnMouseEnter (Widget w, int x, int y)
 
override bool OnMouseLeave (Widget w, Widget enterW, int x, int y)
 
override bool OnMouseButtonUp (Widget w, int x, int y, int button)
 
override bool OnChange (Widget w, int x, int y, bool finished)
 
override bool IsFocusable (Widget w)
 
override bool OnFocus (Widget w, int x, int y)
 
override bool OnFocusLost (Widget w, int x, int y)
 
float NormalizeInput (float value)
 
void SetStep (float step)
 
void SetValue (float value, bool update=true)
 
float GetValue ()
 
void SetMax (float max)
 
override void ColorHighlight (Widget w)
 
override void ColorNormal (Widget w)
 

Private Attributes

protected Widget m_PreviousOption
 
protected Widget m_NextOption
 
protected TextWidget m_SelectedOption
 
protected int m_SelectedOptionIndex
 
protected ref array< stringm_Options
 
protected EditBoxWidget m_EditBox
 
protected SliderWidget m_Slider
 
protected float m_MinValue
 
protected float m_MaxValue
 

Constructor & Destructor Documentation

◆ ~OptionSelector()

void ~OptionSelector ( )
inlineprivate

References m_Root.

◆ ~OptionSelectorEditbox()

void ~OptionSelectorEditbox ( )
inlineprivate

References m_Root.

◆ ~OptionSelectorSliderSetup()

void ~OptionSelectorSliderSetup ( )
inlineprivate

References m_Root.

Member Function Documentation

◆ ColorDisabledConsole()

override void ColorDisabledConsole ( Widget  w)
inlineprivate

References ARGB().

Referenced by ScriptedWidgetEventHandler::Disable().

◆ ColorHighlight() [1/2]

override void ColorHighlight ( Widget  w)
inlineprivate

◆ ColorHighlight() [2/2]

override void ColorHighlight ( Widget  w)
inlineprivate

References ARGB(), and SetFocus().

◆ ColorNormal() [1/2]

override void ColorNormal ( Widget  w)
inlineprivate

◆ ColorNormal() [2/2]

override void ColorNormal ( Widget  w)
inlineprivate

References ARGB().

◆ ColorNormalConsole()

override void ColorNormalConsole ( Widget  w)
inlineprivate

◆ ColorOption()

void ColorOption ( )
inlineprivate

References ARGB().

◆ Disable() [1/3]

override void Disable ( )
inlineprivate

References m_Parent.

◆ Disable() [2/3]

override void Disable ( )
inlineprivate

◆ Disable() [3/3]

override void Disable ( )
inlineprivate

◆ Enable() [1/3]

override void Enable ( )
inlineprivate

References m_Parent.

Referenced by OptionSelectorEditbox().

◆ Enable() [2/3]

override void Enable ( )
inlineprivate

◆ Enable() [3/3]

override void Enable ( )
inlineprivate

◆ GetOptions()

array< string > GetOptions ( )
inlineprivate

◆ GetStringValue()

string GetStringValue ( )
inlineprivate

References string::Get().

◆ GetValue() [1/2]

string GetValue ( )
inlineprivate

Referenced by OnChange(), and SetValue().

◆ GetValue() [2/2]

float GetValue ( )
inlineprivate

References m_MaxValue, m_MinValue, and Math::Round().

◆ IsEnabled()

bool IsEnabled ( )
inlineprivate

Returns 'true' if current index == 1 (default 'enabled' value). Take care, as different selectors may follow different logic!

◆ IsFocusable() [1/3]

◆ IsFocusable() [2/3]

override bool IsFocusable ( Widget  w)
inlineprivate

References m_Parent.

◆ IsFocusable() [3/3]

override bool IsFocusable ( Widget  w)
inlineprivate

References m_Parent.

◆ IsSelectorEnabled()

bool IsSelectorEnabled ( )
inlineprivate

Returns false for the selector in 'disabled' states.

References m_Enabled.

◆ IsSet()

bool IsSet ( )
inlineprivate

◆ NormalizeInput()

float NormalizeInput ( float  value)
inlineprivate

References m_MaxValue, and m_MinValue.

◆ OnChange() [1/2]

override bool OnChange ( Widget  w,
int  x,
int  y,
bool  finished 
)
inlineprivate

References GetValue().

◆ OnChange() [2/2]

override bool OnChange ( Widget  w,
int  x,
int  y,
bool  finished 
)
inlineprivate

References GetValue().

◆ OnClick()

override bool OnClick ( Widget  w,
int  x,
int  y,
int  button 
)
inlineprivate

◆ OnFocus() [1/2]

override bool OnFocus ( Widget  w,
int  x,
int  y 
)
inlineprivate

References GetFocus(), m_Parent, SetFocus(), x, and y.

◆ OnFocus() [2/2]

override bool OnFocus ( Widget  w,
int  x,
int  y 
)
inlineprivate

References GetFocus(), m_Parent, SetFocus(), x, and y.

◆ OnFocusLost() [1/2]

override bool OnFocusLost ( Widget  w,
int  x,
int  y 
)
inlineprivate

References m_Parent, x, and y.

◆ OnFocusLost() [2/2]

override bool OnFocusLost ( Widget  w,
int  x,
int  y 
)
inlineprivate

References m_Parent, x, and y.

◆ OnMouseButtonUp() [1/2]

override bool OnMouseButtonUp ( Widget  w,
int  x,
int  y,
int  button 
)
inlineprivate

◆ OnMouseButtonUp() [2/2]

override bool OnMouseButtonUp ( Widget  w,
int  x,
int  y,
int  button 
)
inlineprivate

◆ OnMouseEnter() [1/3]

override bool OnMouseEnter ( Widget  w,
int  x,
int  y 
)
inlineprivate

References x, and y.

◆ OnMouseEnter() [2/3]

◆ OnMouseEnter() [3/3]

override bool OnMouseEnter ( Widget  w,
int  x,
int  y 
)
inlineprivate

◆ OnMouseLeave() [1/3]

override bool OnMouseLeave ( Widget  w,
Widget  enterW,
int  x,
int  y 
)
inlineprivate

References x, and y.

◆ OnMouseLeave() [2/3]

◆ OnMouseLeave() [3/3]

override bool OnMouseLeave ( Widget  w,
Widget  enterW,
int  x,
int  y 
)
inlineprivate

◆ OptionSelector()

void OptionSelector ( Widget  parent,
int  current_index,
ScriptedWidgetEventHandler  parent_c,
bool  disabled 
)
inlineprivate

◆ OptionSelectorEditbox()

void OptionSelectorEditbox ( Widget  parent,
string  value,
ScriptedWidgetEventHandler  parent_menu,
bool  disabled 
)
inlineprivate

◆ Reset()

void Reset ( )
inlineprivate

◆ SetMax()

void SetMax ( float  max)
inlineprivate

References m_MaxValue.

◆ SetNextOption()

void SetNextOption ( )
inlineprivate

◆ SetPrevOption()

void SetPrevOption ( )
inlineprivate

◆ SetStep()

void SetStep ( float  step)
inlineprivate

◆ SetStringOption()

void SetStringOption ( string  option,
bool  fire_event = true 
)
inlineprivate

◆ SetValue() [1/2]

void SetValue ( float  value,
bool  update = true 
)
inlineprivate

References GetValue(), and Math::Round().

◆ SetValue() [2/2]

void SetValue ( string  value,
bool  update = true 
)
inlineprivate

References GetValue().

Referenced by OptionSelectorEditbox().

Field Documentation

◆ m_EditBox

protected EditBoxWidget m_EditBox
private

◆ m_MaxValue

protected float m_MaxValue
private

◆ m_MinValue

protected float m_MinValue
private

◆ m_NextOption

protected Widget m_NextOption
private

◆ m_Options

protected ref array<string> m_Options
private

◆ m_PreviousOption

protected Widget m_PreviousOption
private

◆ m_SelectedOption

protected TextWidget m_SelectedOption
private

◆ m_SelectedOptionIndex

protected int m_SelectedOptionIndex
private

◆ m_Slider

protected SliderWidget m_Slider
private

The documentation for this class was generated from the following files: