Show / Hide Table of Contents

Class ThemeElement

A base class that is intended to be used on any component/class that needs theming (that's automatically updated), and needs reference to our main class: PomodoroTimer.

Inheritance
System.Object
UnityEngine.Object
UnityEngine.Component
UnityEngine.Behaviour
UnityEngine.MonoBehaviour
ThemeElement
Ghost
ItemSelector<T>
Page
SettingsOptionDropdown
SettingsOptionToggleSlider
BlurOverlay
ConfirmationDialog
ConfirmationDialogManager
DigitFormat
Sidebar
ThemeIconContainer
TomatoCounter
DoubleDigit
SidebarRow
Tomato
ThemeIcon
Background
CompletionLabel
RightButton
SkipButton
ThemeSlider
Implements
IColorHook
Namespace: AdrianMiasik.Components.Base
Assembly: Assembly-CSharp.dll
Syntax
public class ThemeElement : MonoBehaviour, IColorHook

Fields

| Improve this Doc View Source

Timer

Declaration
protected PomodoroTimer Timer
Field Value
Type Description
PomodoroTimer

Methods

| Improve this Doc View Source

ColorUpdate(Theme)

Applies our theme changes to our referenced components when necessary.

Declaration
public virtual void ColorUpdate(Theme theme)
Parameters
Type Name Description
Theme theme
| Improve this Doc View Source

Initialize(PomodoroTimer, Boolean)

Declaration
public virtual void Initialize(PomodoroTimer pomodoroTimer, bool updateColors = true)
Parameters
Type Name Description
PomodoroTimer pomodoroTimer

Our main class

System.Boolean updateColors

Do you want to update or invoke this elements ColorUpdate method on initialization?

| Improve this Doc View Source

IsInitialized()

Fetches this components initialization state.

Declaration
public bool IsInitialized()
Returns
Type Description
System.Boolean

Has this component been initialized yet?

| Improve this Doc View Source

OnDestroy()

De-register itself from the theme on destruction to avoid invoking IColorHook ColorUpdate() on a null reference.

Declaration
public void OnDestroy()

Implements

IColorHook
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX