Vermont-EPSCoR / Macroinvertebrates

Macroinvertebrates Mobile App - Qt Version
MIT License
2 stars 0 forks source link

Sync Appears Fail to For Macroinvertebrates with Long Names #41

Closed MorganRodgers closed 7 years ago

MorganRodgers commented 7 years ago

Invertebrate XML parses OK. Image URL's valid.

MorganRodgers commented 7 years ago

The SingleStreamView has a limited amount of space before it has to truncate its label. That's a problem because I have been using the label as the key to lookup the selected macroinverebrate from the map. Due to the elision of the label the map lookup fails and a default constructed Invertebrate is returned. The default for an Invertebrate is to have all its fields blank, and an image status of ImageStatus::QUEUED_FOR_DOWNLOAD.

SingleStreamView needs a richer model behind it to contain both a link to the Invertebrate it represents and a label that fits in the space available.

MorganRodgers commented 7 years ago

A simple subclass of QListWidgetItem solves the problem.