knowthelist / fhem-tablet-ui

UI builder framework for FHEM
MIT License
148 stars 84 forks source link

widget_slider: // create txt value as original value from the device … #183

Closed viegener closed 7 years ago

viegener commented 7 years ago

…(not via number conversion)

viegener commented 7 years ago

The current implementation uses the device value converts it into a float (via parsefloat) and then converts this back to a string - so the original text value gets lost and will be shown as NaN (not a number).

Showing a string value from the device is the idea of the "textvalue" class

This was corrected already in the past but obviously got lost...

knowthelist commented 7 years ago

Better now? https://github.com/knowthelist/fhem-tablet-ui/commit/29e8551945231d0dd21cb759e042be257c3eeb6b

viegener commented 7 years ago

The current implementation uses the device value converts it into a float (via parsefloat) and then converts this back to a string - so the original text value gets lost and will be shown as NaN (not a number).

Showing a string value from the device is the idea of the "textvalue" class

This was corrected already in the past but obviously got lost...

viegener commented 7 years ago

Change looks good (not yet tested in my system), so I will close the pull request