|
|
@ -20,6 +20,15 @@ bool VarIcon::init(DwinScreen *dwin_screen, uint16_t descript_add) { |
|
|
|
readcfg(); |
|
|
|
return true; |
|
|
|
} |
|
|
|
|
|
|
|
// void VarIcon::initcfg(const char *pos, const char *iconpath, uint16_t initval) {
|
|
|
|
// int posx = 0;
|
|
|
|
// int posy = 0;
|
|
|
|
// sscanf(pos, "(%d,%d)", &posx, &posy);
|
|
|
|
// initcfg(m_dwin_screen->alloc_one_var_icon(), posx, posy, iconpath, initval);
|
|
|
|
// }
|
|
|
|
void VarIcon::initcfg(int x, int y, const char *iconpath, uint16_t initval) { initcfg(m_dwin_screen->alloc_one_var_icon(), x, y, iconpath, initval); } |
|
|
|
|
|
|
|
void VarIcon::initcfg(uint16_t valpointerAdd, uint16_t posx, uint16_t posy, const char *iconpath, uint16_t initval) { |
|
|
|
int iconlib = 0; |
|
|
|
int iconmin = 0; |
|
|
@ -80,6 +89,4 @@ void VarIcon::show() { _setVal(m_val); } |
|
|
|
|
|
|
|
VarIconDescript_t &VarIcon::getDescript() { return m_descript; } |
|
|
|
|
|
|
|
bool VarIcon::_setVal(uint16_t val) { |
|
|
|
return m_dwin_screen->write_varspace16(m_descript.m_VP, val, 100); |
|
|
|
} |
|
|
|
bool VarIcon::_setVal(uint16_t val) { return m_dwin_screen->write_varspace16(m_descript.m_VP, val, 100); } |