mirror of
https://github.com/subsurface/subsurface.git
synced 2025-02-19 22:16:15 +00:00
core: convert taxonomy.c to C++
Since the taxonomy is now a real C++ struct with constructor and destructor, dive_site has to be converted to C++ as well. A bit hairy for now, but will ultimately be distinctly simpler. Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
parent
3c1401785b
commit
3f8b4604be
39 changed files with 259 additions and 336 deletions
|
@ -461,12 +461,12 @@ void LocationFilterDelegate::paint(QPainter *painter, const QStyleOptionViewItem
|
|||
for (int i = 0; i < 3; i++) {
|
||||
if (prefs.geocoding.category[i] == TC_NONE)
|
||||
continue;
|
||||
const char *value = taxonomy_get_value(&ds->taxonomy, prefs.geocoding.category[i]);
|
||||
if (empty_string(value))
|
||||
std::string value = taxonomy_get_value(ds->taxonomy, prefs.geocoding.category[i]);
|
||||
if (!value.empty())
|
||||
continue;
|
||||
if(!bottomText.isEmpty())
|
||||
bottomText += " / ";
|
||||
bottomText += QString(value);
|
||||
bottomText += QString::fromStdString(value);
|
||||
}
|
||||
|
||||
if (bottomText.isEmpty())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue