Class Sidebar
A ThemeElement container page that holds SidebarRow's and deals with group selections and animations. Used to change and switch between our pages/panel contents (Such as main, settings, and about).
Inheritance
Implements
Inherited Members
Namespace: AdrianMiasik.Components.Core.Containers
Assembly: Assembly-CSharp.dll
Syntax
[ExecuteInEditMode]
public class Sidebar : ThemeElement, IColorHook
Methods
| Improve this Doc View SourceCalculateSidebarWidth()
Declaration
public float CalculateSidebarWidth()
Returns
Type | Description |
---|---|
System.Single |
Close()
Instantly closes our sidebar so it can no longer be seen by the user, hides overlay, updates CreditsGhost's colors.
Declaration
public void Close()
ColorUpdate(Theme)
Applies our Theme changes to our referenced components when necessary.
Declaration
public override void ColorUpdate(Theme theme)
Parameters
Type | Name | Description |
---|---|---|
Theme | theme | The theme to apply on our referenced components. |
Overrides
| Improve this Doc View SourceInitialize(PomodoroTimer, ResolutionDetector)
Sets up our SidebarRow's and selects the first one, also calculates and determines the sidebar width based on screen values.
Declaration
public void Initialize(PomodoroTimer pomodoroTimer, ResolutionDetector resolutionDetector)
Parameters
Type | Name | Description |
---|---|---|
PomodoroTimer | pomodoroTimer | |
ResolutionDetector | resolutionDetector |
IsOpen()
Is this Sidebar currently open and visible to the user?
Declaration
public bool IsOpen()
Returns
Type | Description |
---|---|
System.Boolean |
Open()
Animate sidebar open and animate our SidebarRow's in with a stagger, show overlay, and updates CreditsGhost and sidebar colors.
Declaration
public void Open()
SelectRow(SidebarRow, AudioClip)
Deselects all other SidebarRow's and highlights the provided sidebar row.
Declaration
public void SelectRow(SidebarRow rowToSelect, AudioClip clickSoundClip)
Parameters
Type | Name | Description |
---|---|---|
SidebarRow | rowToSelect | |
UnityEngine.AudioClip | clickSoundClip |