Esp32-RBGridUI
Library for creating UIs for the RBController app
Loading...
Searching...
No Matches
Public Member Functions | Friends
gridui::WidgetState Class Reference

#include <widget.h>

Public Member Functions

 WidgetState (uint16_t uuid, float x, float y, float w, float h, uint16_t tab)
 
uint16_t uuid () const
 
std::string getString (const std::string &key, std::string def="") const
 
int64_t getInt (const std::string &key, int64_t def=0) const
 
double getDouble (const std::string &key, double def=0.0) const
 
bool getBool (const std::string &key, bool def=false) const
 
bool set (const std::string &key, rbjson::Value *value)
 
bool setInnerObjectProp (const std::string &objectName, const std::string &propertyName, rbjson::Value *value)
 
void markChanged (const std::string &key)
 
bool hasRegisteredCallbacks () const
 
WidgetPos pos () const
 
void setPos (const WidgetPos &p)
 
std::unique_lock< std::mutex > uniqueStateLock ()
 
const rbjson::Object & dataLocked () const
 

Friends

class gridui::builder::Widget
 
class gridui::_GridUi
 
template<typename Self , typename Finished >
class builder::BuilderMixin
 

Detailed Description

Definition at line 99 of file widget.h.

Constructor & Destructor Documentation

◆ WidgetState()

gridui::WidgetState::WidgetState ( uint16_t  uuid,
float  x,
float  y,
float  w,
float  h,
uint16_t  tab 
)

Definition at line 13 of file widget.cpp.

Member Function Documentation

◆ dataLocked()

const rbjson::Object & gridui::WidgetState::dataLocked ( ) const
inline

Definition at line 139 of file widget.h.

◆ getBool()

bool gridui::WidgetState::getBool ( const std::string &  key,
bool  def = false 
) const

Definition at line 42 of file widget.cpp.

◆ getDouble()

double gridui::WidgetState::getDouble ( const std::string &  key,
double  def = 0.0 
) const

Definition at line 37 of file widget.cpp.

◆ getInt()

int64_t gridui::WidgetState::getInt ( const std::string &  key,
int64_t  def = 0 
) const

Definition at line 32 of file widget.cpp.

◆ getString()

std::string gridui::WidgetState::getString ( const std::string &  key,
std::string  def = "" 
) const

Definition at line 27 of file widget.cpp.

◆ hasRegisteredCallbacks()

bool gridui::WidgetState::hasRegisteredCallbacks ( ) const
inline

Definition at line 122 of file widget.h.

◆ markChanged()

void gridui::WidgetState::markChanged ( const std::string &  key)

Definition at line 142 of file widget.cpp.

◆ pos()

WidgetPos gridui::WidgetState::pos ( ) const
inline

Definition at line 126 of file widget.h.

◆ set()

bool gridui::WidgetState::set ( const std::string &  key,
rbjson::Value *  value 
)

Definition at line 47 of file widget.cpp.

◆ setInnerObjectProp()

bool gridui::WidgetState::setInnerObjectProp ( const std::string &  objectName,
const std::string &  propertyName,
rbjson::Value *  value 
)

Definition at line 64 of file widget.cpp.

◆ setPos()

void gridui::WidgetState::setPos ( const WidgetPos p)
inline

Definition at line 130 of file widget.h.

◆ uniqueStateLock()

std::unique_lock< std::mutex > gridui::WidgetState::uniqueStateLock ( )
inline

Definition at line 136 of file widget.h.

◆ uuid()

uint16_t gridui::WidgetState::uuid ( ) const
inline

Definition at line 109 of file widget.h.

Friends And Related Symbol Documentation

◆ builder::BuilderMixin

template<typename Self , typename Finished >
friend class builder::BuilderMixin
friend

Definition at line 104 of file widget.h.

◆ gridui::_GridUi

friend class gridui::_GridUi
friend

Definition at line 101 of file widget.h.

◆ gridui::builder::Widget

friend class gridui::builder::Widget
friend

Definition at line 100 of file widget.h.


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